#include <TrackDetectorAssociator.h>
Public Types | |
typedef TrackAssociatorParameters | AssociatorParameters |
enum | Direction { Any, InsideOut, OutsideIn } |
Static Public Member Functions | |
static bool | crossedIP (const reco::Track &track) |
static FreeTrajectoryState | getFreeTrajectoryState (const MagneticField *, const reco::Track &) |
get FreeTrajectoryState from different track representations More... | |
static FreeTrajectoryState | getFreeTrajectoryState (const MagneticField *, const SimTrack &, const SimVertex &) |
static FreeTrajectoryState | getFreeTrajectoryState (const MagneticField *, const GlobalVector &, const GlobalPoint &, const int) |
Private Attributes | |
CachedTrajectory | cachedTrajectory_ |
const DetIdAssociator * | caloDetIdAssociator_ |
std::unique_ptr< Propagator > | defProp_ |
const DetIdAssociator * | ecalDetIdAssociator_ |
const DetIdAssociator * | hcalDetIdAssociator_ |
const DetIdAssociator * | hoDetIdAssociator_ |
const Propagator * | ivProp_ |
const DetIdAssociator * | muonDetIdAssociator_ |
const DetIdAssociator * | preshowerDetIdAssociator_ |
const CaloGeometry * | theCaloGeometry_ |
edm::ESWatcher < IdealMagneticFieldRecord > | theMagneticFieldWatcher_ |
const GlobalTrackingGeometry * | theTrackingGeometry_ |
bool | useDefaultPropagator_ |
Definition at line 44 of file TrackDetectorAssociator.h.
Definition at line 49 of file TrackDetectorAssociator.h.
|
explicit |
Definition at line 69 of file TrackDetectorAssociator.cc.
|
default |
|
private |
Definition at line 791 of file TrackDetectorAssociator.cc.
References funct::abs(), spr::deltaEta, reco::deltaPhi(), TrackAssociatorParameters::dRMuon, PV3DBase< T, PVType, FrameType >::eta(), validate-o2o-wbm::f, TrajectoryStateOnSurface::freeState(), TrackingRecHit::geographicalId(), TAMuonSegmentMatch::hasPhi, DTRecSegment4D::hasPhi(), TAMuonSegmentMatch::hasZed, DTRecSegment4D::hasZed(), TAMuonChamberMatch::id, DTRecSegment2D::ist0Valid(), RecSegment::localDirection(), RecSegment::localDirectionError(), TrackingRecHit::localPosition(), TrackingRecHit::localPositionError(), LogTrace, M_PI, PV3DBase< T, PVType, FrameType >::perp(), PV3DBase< T, PVType, FrameType >::phi(), DTRecSegment4D::phiSegment(), FreeTrajectoryState::position(), DetId::rawId(), TAMuonSegmentMatch::segmentGlobalPosition, TAMuonSegmentMatch::segmentLocalDirection, TAMuonSegmentMatch::segmentLocalErrorDxDz, TAMuonSegmentMatch::segmentLocalErrorDyDz, TAMuonSegmentMatch::segmentLocalErrorXDxDz, TAMuonSegmentMatch::segmentLocalErrorXX, TAMuonSegmentMatch::segmentLocalErrorXY, TAMuonSegmentMatch::segmentLocalErrorYDyDz, TAMuonSegmentMatch::segmentLocalErrorYY, TAMuonSegmentMatch::segmentLocalPosition, TAMuonChamberMatch::segments, DTRecSegment2D::specificRecHits(), TAMuonSegmentMatch::t0, DTRecSegment2D::t0(), FrontierCondition_GT_autoExpress_cfi::t0, GeomDet::toGlobal(), TAMuonChamberMatch::tState, LocalError::xx(), LocalError::xy(), and LocalError::yy().
TrackDetMatchInfo TrackDetectorAssociator::associate | ( | const edm::Event & | iEvent, |
const edm::EventSetup & | iSetup, | ||
const FreeTrajectoryState & | fts, | ||
const AssociatorParameters & | parameters | ||
) |
propagate a track across the whole detector and find associated objects. Association is done in two modes 1) an object is associated to a track only if crossed by track 2) an object is associated to a track if it is withing an eta-phi cone of some radius with respect to a track. (the cone origin is at (0,0,0)) Trajectory bending in eta-phi is taking into account when matching is performed
associate using FreeTrajectoryState
Definition at line 110 of file TrackDetectorAssociator.cc.
Referenced by ValidIsoTrkCalib::analyze(), EopTreeWriter::analyze(), EcalCosmicsHists::analyze(), spr::chargeIsolation(), spr::chargeIsolationEcal(), spr::chargeIsolationHcal(), spr::coneChargeIsolation(), muonisolation::CaloExtractorByAssociator::deposits(), cms::MuonMETValueMapProducer::determine_deltax_deltay(), MuonIdProducer::fillMuonId(), and InterestingTrackEcalDetIdProducer::produce().
TrackDetMatchInfo TrackDetectorAssociator::associate | ( | const edm::Event & | iEvent, |
const edm::EventSetup & | iSetup, | ||
const AssociatorParameters & | parameters, | ||
const FreeTrajectoryState * | innerState, | ||
const FreeTrajectoryState * | outerState = nullptr |
||
) |
associate using inner and outer most states of a track in the silicon tracker.
Definition at line 117 of file TrackDetectorAssociator.cc.
References funct::abs(), Exception, info(), init, edm::isNotFinite(), LogTrace, PV3DBase< T, PVType, FrameType >::mag(), CosmicsPD_Skims::maxZ, HLT_FULL_cff::minR, SteppingHelixStateInfo::momentum(), or, PV3DBase< T, PVType, FrameType >::perp(), FreeTrajectoryState::position(), TrackDetMatchInfo::setCaloGeometry(), TrackDetMatchInfo::stateAtIP, TrackDetMatchInfo::trkGlobPosAtEcal, TrackDetMatchInfo::trkGlobPosAtHcal, TrackDetMatchInfo::trkGlobPosAtHO, TrackDetMatchInfo::trkMomAtEcal, TrackDetMatchInfo::trkMomAtHcal, TrackDetMatchInfo::trkMomAtHO, TrackAssociatorParameters::truthMatch, TrackAssociatorParameters::useCalo, TrackAssociatorParameters::useEcal, TrackAssociatorParameters::useHcal, TrackAssociatorParameters::useHO, TrackAssociatorParameters::useMuon, TrackAssociatorParameters::usePreshower, PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), and PV3DBase< T, PVType, FrameType >::z().
TrackDetMatchInfo TrackDetectorAssociator::associate | ( | const edm::Event & | iEvent, |
const edm::EventSetup & | iSetup, | ||
const reco::Track & | track, | ||
const AssociatorParameters & | parameters, | ||
Direction | direction = Any |
||
) |
associate using reco::Track
Definition at line 955 of file TrackDetectorAssociator.cc.
References funct::abs(), ecalTB2006H4_GenSimDigiReco_cfg::bField, TrackAssociatorParameters::bFieldToken, Exception, reco::Track::extra(), edm::EventSetup::getData(), trajectoryStateTransform::initialFreeState(), trajectoryStateTransform::innerFreeState(), reco::Track::innerMomentum(), reco::Track::innerPosition(), edm::Ref< C, T, F >::isNull(), LogTrace, trajectoryStateTransform::outerFreeState(), reco::Track::outerMomentum(), reco::Track::outerPosition(), PV3DBase< T, PVType, FrameType >::perp(), PV3DBase< T, PVType, FrameType >::phi(), FreeTrajectoryState::position(), mps_fire::result, and PV3DBase< T, PVType, FrameType >::z().
TrackDetMatchInfo TrackDetectorAssociator::associate | ( | const edm::Event & | iEvent, |
const edm::EventSetup & | iSetup, | ||
const SimTrack & | track, | ||
const SimVertex & | vertex, | ||
const AssociatorParameters & | parameters | ||
) |
associate using a simulated track
Definition at line 1037 of file TrackDetectorAssociator.cc.
References ecalTB2006H4_GenSimDigiReco_cfg::bField, TrackAssociatorParameters::bFieldToken, and edm::EventSetup::getData().
TrackDetMatchInfo TrackDetectorAssociator::associate | ( | const edm::Event & | iEvent, |
const edm::EventSetup & | iSetup, | ||
const GlobalVector & | momentum, | ||
const GlobalPoint & | vertex, | ||
const int | charge, | ||
const AssociatorParameters & | parameters | ||
) |
associate using 3-momentum, vertex and charge
Definition at line 1046 of file TrackDetectorAssociator.cc.
References ecalTB2006H4_GenSimDigiReco_cfg::bField, TrackAssociatorParameters::bFieldToken, and edm::EventSetup::getData().
|
static |
Definition at line 1056 of file TrackDetectorAssociator.cc.
References reco::Track::innerMomentum(), reco::Track::innerPosition(), reco::Track::outerMomentum(), and reco::Track::outerPosition().
Referenced by MuonIdProducer::produce().
|
private |
Definition at line 295 of file TrackDetectorAssociator.cc.
References TrackAssociatorParameters::accountForTrajectoryChangeCalo, HiRecoJets_cff::caloTowers, TrackAssociatorParameters::caloTowersToken, TrackDetMatchInfo::crossedTowerIds, TrackDetMatchInfo::crossedTowers, HLT_FULL_cff::distance, TrackAssociatorParameters::dRHcal, TrackAssociatorParameters::dRHcalPreselection, edm::Event::getByToken(), CachedTrajectory::IpToHcal, TrackDetMatchInfo::isGoodCalo, edm::HandleBase::isValid(), LogTrace, hgcalTowerProducer_cfi::tower, and TrackDetMatchInfo::towers.
|
private |
Definition at line 888 of file TrackDetectorAssociator.cc.
References funct::abs(), HLT_FULL_cff::DeltaR, TrackDetMatchInfo::ecalTrueEnergy, validate-o2o-wbm::f, SimTrack::genpartIndex(), edm::Event::getByToken(), TrackDetMatchInfo::hcalTrueEnergy, TrackDetMatchInfo::hcalTrueEnergyCorrected, FreeTrajectoryState::momentum(), TrackAssociatorParameters::simEcalHitsEBToken, TrackAssociatorParameters::simEcalHitsEEToken, TrackAssociatorParameters::simHcalHitsToken, cscDigiValidation_cfi::simTrack, TrackDetMatchInfo::simTrack, TrackAssociatorParameters::simTracksToken, TrackAssociatorParameters::simVerticesToken, TrackDetMatchInfo::stateAtIP, TrackDetMatchInfo::trkGlobPosAtHcal, PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), and PV3DBase< T, PVType, FrameType >::z().
|
private |
Definition at line 221 of file TrackDetectorAssociator.cc.
References TrackAssociatorParameters::accountForTrajectoryChangeCalo, TrackDetMatchInfo::crossedEcalIds, TrackDetMatchInfo::crossedEcalRecHits, TrackAssociatorParameters::dREcal, TrackAssociatorParameters::dREcalPreselection, egHLT::errCodes::EBRecHits, TrackAssociatorParameters::EBRecHitsToken, TrackDetMatchInfo::ecalRecHits, egHLT::errCodes::EERecHits, TrackAssociatorParameters::EERecHitsToken, edm::Event::getByToken(), CachedTrajectory::IpToEcal, TrackDetMatchInfo::isGoodEcal, edm::HandleBase::isValid(), and LogTrace.
|
private |
Definition at line 392 of file TrackDetectorAssociator.cc.
References TrackAssociatorParameters::accountForTrajectoryChangeCalo, universalConfigTemplate::collection, TrackDetMatchInfo::crossedHcalIds, TrackDetMatchInfo::crossedHcalRecHits, HLT_FULL_cff::distance, TrackAssociatorParameters::dRHcal, TrackAssociatorParameters::dRHcalPreselection, edm::Event::getByToken(), TrackAssociatorParameters::HBHEcollToken, TrackDetMatchInfo::hcalRecHits, DetIdInfo::info(), CachedTrajectory::IpToHcal, TrackDetMatchInfo::isGoodHcal, edm::HandleBase::isValid(), and LogTrace.
|
private |
Definition at line 460 of file TrackDetectorAssociator.cc.
References TrackAssociatorParameters::accountForTrajectoryChangeCalo, universalConfigTemplate::collection, TrackDetMatchInfo::crossedHOIds, TrackDetMatchInfo::crossedHORecHits, HLT_FULL_cff::distance, TrackAssociatorParameters::dRHcal, TrackAssociatorParameters::dRHcalPreselection, edm::Event::getByToken(), TrackAssociatorParameters::HOcollToken, TrackDetMatchInfo::hoRecHits, CachedTrajectory::IpToHO, TrackDetMatchInfo::isGoodHO, edm::HandleBase::isValid(), and LogTrace.
|
private |
Definition at line 693 of file TrackDetectorAssociator.cc.
References TrackDetMatchInfo::chambers, cscSegments_cfi::cscSegments, TrackAssociatorParameters::cscSegmentsToken, TrackAssociatorParameters::dtSegmentsToken, gemSegments_cfi::gemSegments, TrackAssociatorParameters::gemSegmentsToken, edm::Event::getByToken(), edm::HandleBase::isValid(), LogTrace, me0Segments_cfi::me0Segments, TrackAssociatorParameters::me0SegmentsToken, sistrip::SpyUtilities::range(), TrackAssociatorParameters::useGEM, and TrackAssociatorParameters::useME0.
|
private |
Definition at line 369 of file TrackDetectorAssociator.cc.
References TrackDetMatchInfo::crossedPreshowerIds, TrackAssociatorParameters::dRPreshowerPreselection, and LogTrace.
|
inline |
trajector information
Definition at line 93 of file TrackDetectorAssociator.h.
References cachedTrajectory_.
|
static |
get FreeTrajectoryState from different track representations
Definition at line 553 of file TrackDetectorAssociator.cc.
References ecalTB2006H4_GenSimDigiReco_cfg::bField, reco::TrackBase::charge(), alignCSCRings::e, gpuClustering::id, reco::TrackBase::momentum(), point, trackerHitRTTI::vector, and reco::TrackBase::vertex().
Referenced by ValidIsoTrkCalib::analyze(), EopTreeWriter::analyze(), spr::chargeIsolation(), spr::chargeIsolationEcal(), spr::chargeIsolationHcal(), spr::coneChargeIsolation(), cms::MuonMETValueMapProducer::determine_deltax_deltay(), and InterestingTrackEcalDetIdProducer::produce().
|
static |
Definition at line 525 of file TrackDetectorAssociator.cc.
References funct::abs(), RecoTauCleanerPlugins::charge, CoreSimTrack::momentum(), point, CoreSimVertex::position(), CoreSimTrack::type(), and trackerHitRTTI::vector.
|
static |
Definition at line 539 of file TrackDetectorAssociator.cc.
References alignCSCRings::e, and gpuClustering::id.
|
private |
Definition at line 572 of file TrackDetectorAssociator.cc.
References funct::abs(), DetIdAssociator::MapRange::dPhiMinus, DetIdAssociator::MapRange::dPhiPlus, DetIdAssociator::MapRange::dThetaMinus, DetIdAssociator::MapRange::dThetaPlus, and LogTrace.
|
inlineprivate |
Definition at line 135 of file TrackDetectorAssociator.h.
References point.
|
inlineprivate |
Definition at line 139 of file TrackDetectorAssociator.h.
References point.
|
private |
Definition at line 592 of file TrackDetectorAssociator.cc.
References funct::abs(), Surface::bounds(), TrackAssociatorParameters::dRMuonPreselection, validate-o2o-wbm::f, TrajectoryStateOnSurface::freeState(), CachedTrajectory::FullTrajectory, TAMuonChamberMatch::id, DetIdInfo::info(), TrajectoryStateOnSurface::isValid(), SteppingHelixStateInfo::isValid(), Bounds::length(), CSCWireTopology::lengthOfPlane(), TAMuonChamberMatch::localDistanceX, TAMuonChamberMatch::localDistanceY, TrajectoryStateOnSurface::localError(), LogTrace, match(), SteppingHelixStateInfo::momentum(), TrackAssociatorParameters::muonMaxDistanceSigmaX, TrackAssociatorParameters::muonMaxDistanceSigmaY, TrackAssociatorParameters::muonMaxDistanceX, TrackAssociatorParameters::muonMaxDistanceY, CSCWireTopology::narrowWidthOfPlane(), CSCChamberSpecs::oddLayerGeometry(), SteppingHelixStateInfo::position(), FreeTrajectoryState::position(), LocalTrajectoryError::positionError(), mathSSE::sqrt(), GeomDet::surface(), GloballyPositioned< T >::toLocal(), TAMuonChamberMatch::tState, Vector3DBase< T, FrameTag >::unit(), CSCWireTopology::wideWidthOfPlane(), Bounds::width(), CSCWireTopology::wireAngle(), CSCLayerGeometry::wireTopology(), PV3DBase< T, PVType, FrameType >::x(), LocalError::xx(), PV3DBase< T, PVType, FrameType >::y(), CSCWireTopology::yOfWire(), and LocalError::yy().
|
inlineprivate |
Definition at line 143 of file TrackDetectorAssociator.h.
|
inlineprivate |
Definition at line 145 of file TrackDetectorAssociator.h.
|
private |
Definition at line 83 of file TrackDetectorAssociator.cc.
References anyDirection, ecalTB2006H4_GenSimDigiReco_cfg::bField, TrackAssociatorParameters::bFieldToken, TrackAssociatorParameters::caloDetIdAssociatorToken, TrackAssociatorParameters::ecalDetIdAssociatorToken, edm::EventSetup::getData(), TrackAssociatorParameters::hcalDetIdAssociatorToken, TrackAssociatorParameters::hoDetIdAssociatorToken, eostools::move(), TrackAssociatorParameters::muonDetIdAssociatorToken, TrackAssociatorParameters::preshowerDetIdAssociatorToken, TrackAssociatorParameters::theCaloGeometryToken, and TrackAssociatorParameters::theTrackingGeometryToken.
void TrackDetectorAssociator::setPropagator | ( | const Propagator * | ptr | ) |
use a user configured propagator
Definition at line 76 of file TrackDetectorAssociator.cc.
Referenced by muonisolation::CaloExtractorByAssociator::deposits(), and MuonIdProducer::init().
void TrackDetectorAssociator::useDefaultPropagator | ( | ) |
use the default propagator
Definition at line 81 of file TrackDetectorAssociator.cc.
Referenced by EopTreeWriter::analyze(), EcalCosmicsHists::EcalCosmicsHists(), InterestingTrackEcalDetIdProducer::InterestingTrackEcalDetIdProducer(), cms::MuonMETValueMapProducer::MuonMETValueMapProducer(), pat::PATIsolatedTrackProducer::PATIsolatedTrackProducer(), and ValidIsoTrkCalib::ValidIsoTrkCalib().
|
private |
Definition at line 149 of file TrackDetectorAssociator.h.
Referenced by getCachedTrajector().
|
private |
Definition at line 155 of file TrackDetectorAssociator.h.
|
private |
Definition at line 148 of file TrackDetectorAssociator.h.
|
private |
Definition at line 152 of file TrackDetectorAssociator.h.
|
private |
Definition at line 153 of file TrackDetectorAssociator.h.
|
private |
Definition at line 154 of file TrackDetectorAssociator.h.
|
private |
Definition at line 147 of file TrackDetectorAssociator.h.
|
private |
Definition at line 156 of file TrackDetectorAssociator.h.
|
private |
Definition at line 157 of file TrackDetectorAssociator.h.
|
private |
Definition at line 159 of file TrackDetectorAssociator.h.
|
private |
Definition at line 162 of file TrackDetectorAssociator.h.
|
private |
Definition at line 160 of file TrackDetectorAssociator.h.
|
private |
Definition at line 150 of file TrackDetectorAssociator.h.