#include <SimHitMatcher.h>
Public Member Functions | |
std::set< unsigned int > | chamberIdsGEM () const |
GEM chamber detIds with SimHits. More... | |
std::set< unsigned int > | detIdsGEM () const |
GEM partitions' detIds with SimHits. More... | |
std::set< unsigned int > | detIdsGEMCoincidences () const |
std::set< int > | hitCoPadsInDetId (unsigned int) const |
std::set< int > | hitPadsInDetId (unsigned int) const |
std::set< int > | hitPartitions () const |
const edm::PSimHitContainer & | hitsInChamber (unsigned int) const |
const edm::PSimHitContainer & | hitsInDetId (unsigned int) const |
simhits from a particular partition (GEM)/layer (CSC), chamber or superchamber More... | |
const edm::PSimHitContainer & | hitsInSuperChamber (unsigned int) const |
std::set< int > | hitStripsInDetId (unsigned int, int margin_n_strips=0) const |
int | nCoincidencePadsWithHits () const |
How many coincidence pads with simhits in GEM did this simtrack get? More... | |
int | nLayersWithHitsInSuperChamber (unsigned int) const |
int | nPadsWithHits () const |
How many pads with simhits in GEM did this simtrack get? More... | |
SimHitMatcher (const SimTrack &track, const edm::Event &, const GEMGeometry &geom, const edm::ParameterSet &cfg, edm::EDGetToken &simhitToken, edm::EDGetToken &simtrackToken, edm::EDGetToken &simvertexToken) | |
const edm::PSimHitContainer & | simHitsGEM () const |
access to all the GEM SimHits More... | |
GlobalPoint | simHitsMeanPosition (const edm::PSimHitContainer &sim_hits) const |
calculate Global average position for a provided collection of simhits More... | |
float | simHitsMeanStrip (const edm::PSimHitContainer &sim_hits) const |
calculate average strip (strip for GEM, half-strip for CSC) number for a provided collection of simhits More... | |
std::set< unsigned int > | superChamberIdsGEM () const |
GEM superchamber detIds with SimHits. More... | |
std::set< unsigned int > | superChamberIdsGEMCoincidences () const |
GEM superchamber detIds with SimHits 2 layers of coincidence pads. More... | |
~SimHitMatcher () | |
Private Member Functions | |
std::vector< unsigned int > | getIdsOfSimTrackShower (unsigned trk_id, const edm::SimTrackContainer &simTracks, const edm::SimVertexContainer &simVertices) |
void | init (const edm::Event &) |
void | matchSimHitsToSimTrack (std::vector< unsigned int > track_ids, const edm::PSimHitContainer &gem_hits) |
Private Attributes | |
bool | discardEleHitsGEM_ |
std::map< unsigned int, edm::PSimHitContainer > | gem_chamber_to_hits_ |
std::map< unsigned int, edm::PSimHitContainer > | gem_detid_to_hits_ |
std::map< unsigned int, std::set< int > > | gem_detids_to_copads_ |
std::map< unsigned int, std::set< int > > | gem_detids_to_pads_ |
const GEMGeometry & | gem_geo_ |
edm::Handle< edm::PSimHitContainer > | gem_hits |
edm::PSimHitContainer | gem_hits_ |
std::map< unsigned int, edm::PSimHitContainer > | gem_superchamber_to_hits_ |
edm::PSimHitContainer | no_hits_ |
edm::Handle< edm::SimTrackContainer > | sim_tracks |
edm::Handle< edm::SimVertexContainer > | sim_vertices |
std::string | simInputLabel_ |
bool | simMuOnlyGEM_ |
const SimTrack & | track_ |
std::map< unsigned int, unsigned int > | trkid_to_index_ |
bool | verbose_ |
Description: Matching of SimHit for SimTrack in CSC & GEM
Original Author: "Vadim Khotilovich"
Definition at line 32 of file SimHitMatcher.h.
SimHitMatcher::SimHitMatcher | ( | const SimTrack & | track, |
const edm::Event & | e, | ||
const GEMGeometry & | geom, | ||
const edm::ParameterSet & | cfg, | ||
edm::EDGetToken & | simhitToken, | ||
edm::EDGetToken & | simtrackToken, | ||
edm::EDGetToken & | simvertexToken | ||
) |
Definition at line 25 of file SimHitMatcher.cc.
References discardEleHitsGEM_, gem_hits, edm::Event::getByToken(), edm::ParameterSet::getUntrackedParameter(), init(), sim_tracks, sim_vertices, simInputLabel_, simMuOnlyGEM_, AlCaHLTBitMon_QueryRunRegistry::string, and verbose_.
SimHitMatcher::~SimHitMatcher | ( | ) |
Definition at line 39 of file SimHitMatcher.cc.
std::set< unsigned int > SimHitMatcher::chamberIdsGEM | ( | ) | const |
GEM chamber detIds with SimHits.
Definition at line 219 of file SimHitMatcher.cc.
References gem_chamber_to_hits_, AlCaHLTBitMon_ParallelJobs::p, and mps_fire::result.
Referenced by GEMSimTrackMatch::analyze(), GEMDigiTrackMatch::analyze(), GEMRecHitTrackMatch::analyze(), init(), and simHitsGEM().
std::set< unsigned int > SimHitMatcher::detIdsGEM | ( | ) | const |
GEM partitions' detIds with SimHits.
Definition at line 203 of file SimHitMatcher.cc.
References gem_detid_to_hits_, AlCaHLTBitMon_ParallelJobs::p, and mps_fire::result.
Referenced by hitPartitions(), init(), GEMDigiMatcher::matchDigisToSimTrack(), GEMDigiMatcher::matchPadsToSimTrack(), GEMRecHitMatcher::matchRecHitsToSimTrack(), matchSimHitsToSimTrack(), nPadsWithHits(), and simHitsGEM().
std::set< unsigned int > SimHitMatcher::detIdsGEMCoincidences | ( | ) | const |
GEM detid's with hits in 2 layers of coincidence pads those are layer==1 only detid's
Definition at line 211 of file SimHitMatcher.cc.
References gem_detids_to_copads_, AlCaHLTBitMon_ParallelJobs::p, and mps_fire::result.
Referenced by GEMDigiMatcher::matchCoPadsToSimTrack(), nCoincidencePadsWithHits(), and simHitsGEM().
|
private |
Definition at line 89 of file SimHitMatcher.cc.
References TrackValidation_cff::association, SimTrack::noVertex(), mps_fire::result, simMuOnlyGEM_, lumiQTWidget::t, trkid_to_index_, and SimTrack::vertIndex().
Referenced by init().
std::set< int > SimHitMatcher::hitCoPadsInDetId | ( | unsigned int | detid | ) | const |
Definition at line 385 of file SimHitMatcher.cc.
References gem_detids_to_copads_, and none.
Referenced by GEMDigiMatcher::matchCoPadsToSimTrack(), nCoincidencePadsWithHits(), and simHitsGEM().
std::set< int > SimHitMatcher::hitPadsInDetId | ( | unsigned int | detid | ) | const |
Definition at line 377 of file SimHitMatcher.cc.
References gem_detids_to_pads_, and none.
Referenced by GEMDigiMatcher::matchPadsToSimTrack(), nPadsWithHits(), and simHitsGEM().
std::set< int > SimHitMatcher::hitPartitions | ( | ) | const |
Definition at line 393 of file SimHitMatcher.cc.
References detIdsGEM(), mps_fire::result, and GEMDetId::roll().
Referenced by simHitsGEM().
const edm::PSimHitContainer & SimHitMatcher::hitsInChamber | ( | unsigned int | detid | ) | const |
Definition at line 262 of file SimHitMatcher.cc.
References gem_chamber_to_hits_, triggerObjects_cff::id, and no_hits_.
Referenced by init(), and simHitsGEM().
const edm::PSimHitContainer & SimHitMatcher::hitsInDetId | ( | unsigned int | detid | ) | const |
simhits from a particular partition (GEM)/layer (CSC), chamber or superchamber
Definition at line 250 of file SimHitMatcher.cc.
References gem_detid_to_hits_, and no_hits_.
Referenced by hitStripsInDetId(), init(), matchSimHitsToSimTrack(), and simHitsGEM().
const edm::PSimHitContainer & SimHitMatcher::hitsInSuperChamber | ( | unsigned int | detid | ) | const |
Definition at line 275 of file SimHitMatcher.cc.
References gem_superchamber_to_hits_, triggerObjects_cff::id, and no_hits_.
Referenced by init(), nLayersWithHitsInSuperChamber(), and simHitsGEM().
std::set< int > SimHitMatcher::hitStripsInDetId | ( | unsigned int | detid, |
int | margin_n_strips = 0 |
||
) | const |
Definition at line 355 of file SimHitMatcher.cc.
References Topology::channel(), GEMGeometry::etaPartition(), gem_geo_, h, hitsInDetId(), triggerObjects_cff::id, GEMEtaPartition::nstrips(), mps_fire::result, and GEMEtaPartition::topology().
Referenced by init(), GEMDigiMatcher::matchDigisToSimTrack(), GEMRecHitMatcher::matchRecHitsToSimTrack(), and simHitsGEM().
|
private |
Definition at line 42 of file SimHitMatcher.cc.
References chamberIdsGEM(), popcon2dropbox::copy(), gather_cfg::cout, detIdsGEM(), gem_chamber_to_hits_, gem_detid_to_hits_, gem_hits, gem_superchamber_to_hits_, getIdsOfSimTrackShower(), hitsInChamber(), hitsInDetId(), hitsInSuperChamber(), hitStripsInDetId(), triggerObjects_cff::id, matchSimHitsToSimTrack(), nCoincidencePadsWithHits(), edm::Handle< T >::product(), sim_tracks, sim_vertices, simHitsMeanPosition(), RecoTauPiZeroBuilderPlugins_cfi::strips, superChamberIdsGEM(), lumiQTWidget::t, track_, CoreSimTrack::trackId(), trkid_to_index_, and verbose_.
Referenced by SimHitMatcher(), and simHitsGEM().
|
private |
Definition at line 127 of file SimHitMatcher.cc.
References funct::abs(), GEMDetId::chamber(), edmIntegrityCheck::d, detIdsGEM(), discardEleHitsGEM_, GEMGeometry::etaPartition(), gem_chamber_to_hits_, gem_detid_to_hits_, gem_detids_to_copads_, gem_detids_to_pads_, gem_geo_, gem_hits_, gem_superchamber_to_hits_, h, hfClusterShapes_cfi::hits, hitsInDetId(), triggerObjects_cff::id, globals_cff::id1, globals_cff::id2, GEMDetId::layer(), BPhysicsValidation_cfi::pdgid, GEMDetId::region(), GEMDetId::ring(), GEMDetId::roll(), simMuOnlyGEM_, and GEMDetId::station().
Referenced by init().
int SimHitMatcher::nCoincidencePadsWithHits | ( | ) | const |
How many coincidence pads with simhits in GEM did this simtrack get?
Definition at line 420 of file SimHitMatcher.cc.
References detIdsGEMCoincidences(), hitCoPadsInDetId(), and mps_fire::result.
Referenced by init(), and simHitsGEM().
int SimHitMatcher::nLayersWithHitsInSuperChamber | ( | unsigned int | detid | ) | const |
#layers with hits for CSC: "super-chamber" means chamber
Definition at line 288 of file SimHitMatcher.cc.
References h, hfClusterShapes_cfi::hits, and hitsInSuperChamber().
Referenced by simHitsGEM().
int SimHitMatcher::nPadsWithHits | ( | ) | const |
How many pads with simhits in GEM did this simtrack get?
Definition at line 408 of file SimHitMatcher.cc.
References detIdsGEM(), hitPadsInDetId(), and mps_fire::result.
Referenced by simHitsGEM().
|
inline |
access to all the GEM SimHits
Definition at line 41 of file SimHitMatcher.h.
References chamberIdsGEM(), detIdsGEM(), detIdsGEMCoincidences(), gem_hits_, hitCoPadsInDetId(), hitPadsInDetId(), hitPartitions(), hitsInChamber(), hitsInDetId(), hitsInSuperChamber(), hitStripsInDetId(), init(), nCoincidencePadsWithHits(), nLayersWithHitsInSuperChamber(), nPadsWithHits(), simHitsMeanPosition(), simHitsMeanStrip(), superChamberIdsGEM(), and superChamberIdsGEMCoincidences().
GlobalPoint SimHitMatcher::simHitsMeanPosition | ( | const edm::PSimHitContainer & | sim_hits | ) | const |
calculate Global average position for a provided collection of simhits
Definition at line 305 of file SimHitMatcher.cc.
References gem_geo_, runTauDisplay::gp, h, GEMGeometry::idToDet(), gen::n, GeomDet::toGlobal(), PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), and PV3DBase< T, PVType, FrameType >::z().
Referenced by init(), and simHitsGEM().
float SimHitMatcher::simHitsMeanStrip | ( | const edm::PSimHitContainer & | sim_hits | ) | const |
calculate average strip (strip for GEM, half-strip for CSC) number for a provided collection of simhits
Definition at line 331 of file SimHitMatcher.cc.
References edmIntegrityCheck::d, GEMGeometry::etaPartition(), f, gem_geo_, h, gen::n, alignCSCRings::s, and GEMEtaPartition::strip().
Referenced by simHitsGEM().
std::set< unsigned int > SimHitMatcher::superChamberIdsGEM | ( | ) | const |
GEM superchamber detIds with SimHits.
Definition at line 228 of file SimHitMatcher.cc.
References gem_superchamber_to_hits_, AlCaHLTBitMon_ParallelJobs::p, and mps_fire::result.
Referenced by init(), and simHitsGEM().
std::set< unsigned int > SimHitMatcher::superChamberIdsGEMCoincidences | ( | ) | const |
GEM superchamber detIds with SimHits 2 layers of coincidence pads.
Definition at line 237 of file SimHitMatcher.cc.
References gem_detids_to_copads_, triggerObjects_cff::id, AlCaHLTBitMon_ParallelJobs::p, and mps_fire::result.
Referenced by simHitsGEM().
|
private |
Definition at line 94 of file SimHitMatcher.h.
Referenced by matchSimHitsToSimTrack(), and SimHitMatcher().
|
private |
Definition at line 109 of file SimHitMatcher.h.
Referenced by chamberIdsGEM(), hitsInChamber(), init(), and matchSimHitsToSimTrack().
|
private |
Definition at line 108 of file SimHitMatcher.h.
Referenced by detIdsGEM(), hitsInDetId(), init(), and matchSimHitsToSimTrack().
|
private |
Definition at line 115 of file SimHitMatcher.h.
Referenced by detIdsGEMCoincidences(), hitCoPadsInDetId(), matchSimHitsToSimTrack(), and superChamberIdsGEMCoincidences().
|
private |
Definition at line 113 of file SimHitMatcher.h.
Referenced by hitPadsInDetId(), and matchSimHitsToSimTrack().
|
private |
Definition at line 103 of file SimHitMatcher.h.
Referenced by hitStripsInDetId(), matchSimHitsToSimTrack(), simHitsMeanPosition(), and simHitsMeanStrip().
|
private |
Definition at line 98 of file SimHitMatcher.h.
Referenced by init(), and SimHitMatcher().
|
private |
Definition at line 107 of file SimHitMatcher.h.
Referenced by matchSimHitsToSimTrack(), and simHitsGEM().
|
private |
Definition at line 110 of file SimHitMatcher.h.
Referenced by hitsInSuperChamber(), init(), matchSimHitsToSimTrack(), and superChamberIdsGEM().
|
private |
Definition at line 106 of file SimHitMatcher.h.
Referenced by hitsInChamber(), hitsInDetId(), and hitsInSuperChamber().
|
private |
Definition at line 99 of file SimHitMatcher.h.
Referenced by init(), and SimHitMatcher().
|
private |
Definition at line 100 of file SimHitMatcher.h.
Referenced by init(), and SimHitMatcher().
|
private |
Definition at line 96 of file SimHitMatcher.h.
Referenced by SimHitMatcher().
|
private |
Definition at line 93 of file SimHitMatcher.h.
Referenced by getIdsOfSimTrackShower(), matchSimHitsToSimTrack(), and SimHitMatcher().
|
private |
Definition at line 87 of file SimHitMatcher.h.
Referenced by init().
|
private |
Definition at line 104 of file SimHitMatcher.h.
Referenced by getIdsOfSimTrackShower(), and init().
|
private |
Definition at line 95 of file SimHitMatcher.h.
Referenced by init(), and SimHitMatcher().