src
RecoMuon
MuonIsolation
plugins
CaloExtractorByAssociator.h
Go to the documentation of this file.
1
#ifndef MuonIsolation_CaloExtractorByAssociator_H
2
#define MuonIsolation_CaloExtractorByAssociator_H
3
14
#include <string>
15
16
#include "
PhysicsTools/IsolationAlgos/interface/IsoDepositExtractor.h
"
17
18
#include "
FWCore/Framework/interface/ConsumesCollector.h
"
19
20
#include "
DataFormats/RecoCandidate/interface/IsoDeposit.h
"
21
#include "
DataFormats/TrackReco/interface/Track.h
"
22
#include "
DataFormats/TrackReco/interface/TrackFwd.h
"
23
24
#include "
DataFormats/CaloTowers/interface/CaloTowerCollection.h
"
25
26
#include "
DataFormats/GeometryVector/interface/GlobalPoint.h
"
27
28
#include "
CondFormats/EcalObjects/interface/EcalPFRecHitThresholds.h
"
29
#include "
CondFormats/DataRecord/interface/EcalPFRecHitThresholdsRcd.h
"
30
#include "
CondFormats/DataRecord/interface/HcalPFCutsRcd.h
"
31
#include "
CondFormats/HcalObjects/interface/HcalChannelQuality.h
"
32
#include "
CondFormats/DataRecord/interface/HcalChannelQualityRcd.h
"
33
#include "
CondTools/Hcal/interface/HcalPFCutsHandler.h
"
34
35
#include "
Geometry/CaloGeometry/interface/CaloGeometry.h
"
36
#include "
Geometry/CaloTopology/interface/HcalTopology.h
"
37
#include "
Geometry/Records/interface/CaloGeometryRecord.h
"
38
#include "
MagneticField/Engine/interface/MagneticField.h
"
39
#include "
MagneticField/Records/interface/IdealMagneticFieldRecord.h
"
40
#include "
RecoLocalCalo/HcalRecAlgos/interface/HcalSeverityLevelComputer.h
"
41
#include "
RecoLocalCalo/HcalRecAlgos/interface/HcalSeverityLevelComputerRcd.h
"
42
43
class
TrackAssociatorParameters
;
44
class
TrackDetectorAssociator
;
45
class
MuonServiceProxy
;
46
47
namespace
muonisolation
{
48
49
class
CaloExtractorByAssociator
:
public
reco::isodeposit::IsoDepositExtractor
{
50
public
:
52
CaloExtractorByAssociator
(){};
53
CaloExtractorByAssociator
(
const
edm::ParameterSet
& par,
edm::ConsumesCollector
&& iC);
54
56
~CaloExtractorByAssociator
()
override
;
57
59
void
fillVetos
(
const
edm::Event
&
ev
,
const
edm::EventSetup
& evSetup,
const
reco::TrackCollection
&
tracks
)
override
;
61
reco::IsoDeposit
deposit
(
const
edm::Event
&
ev
,
62
const
edm::EventSetup
& evSetup,
63
const
reco::Track
&
track
)
const override
;
65
std::vector<reco::IsoDeposit>
deposits
(
const
edm::Event
&
ev
,
66
const
edm::EventSetup
& evSetup,
67
const
reco::Track
&
track
)
const override
;
68
69
private
:
71
bool
theUseEcalRecHitsFlag
;
72
bool
theUseHcalRecHitsFlag
;
73
bool
theUseHORecHitsFlag
;
74
76
std::string
theDepositLabel
;
77
79
std::vector<std::string>
theDepositInstanceLabels
;
80
82
std::string
thePropagatorName
;
83
86
double
theThreshold_E
;
87
double
theThreshold_H
;
88
double
theThreshold_HO
;
89
int
theMaxSeverityHB
;
90
int
theMaxSeverityHE
;
91
93
double
theDR_Veto_E
;
94
double
theDR_Veto_H
;
95
double
theDR_Veto_HO
;
98
bool
theCenterConeOnCalIntersection
;
100
double
theDR_Max
;
101
104
double
theNoise_EB
;
105
double
theNoise_EE
;
106
double
theNoise_HB
;
107
double
theNoise_HE
;
108
double
theNoise_HO
;
109
double
theNoiseTow_EB
;
110
double
theNoiseTow_EE
;
111
113
std::vector<DetId>
theVetoCollection
;
114
116
MuonServiceProxy
*
theService
;
117
119
TrackAssociatorParameters
*
theAssociatorParameters
;
120
TrackDetectorAssociator
*
theAssociator
;
121
122
edm::ESGetToken<MagneticField, IdealMagneticFieldRecord>
bFieldToken_
;
123
edm::ESGetToken<CaloGeometry, CaloGeometryRecord>
caloGeomToken_
;
124
125
// Ecal noise thresholds
126
edm::ESGetToken<EcalPFRecHitThresholds, EcalPFRecHitThresholdsRcd>
ecalPFRechitThresholdsToken_
;
127
bool
ecalRecHitThresh_
;
128
EcalPFRecHitThresholds
*
ecalThresholds
=
nullptr
;
129
130
// following are needed to grab HCal thresholds from GT
131
edm::ESGetToken<HcalPFCuts, HcalPFCutsRcd>
hcalCutsToken_
;
132
bool
hcalCutsFromDB_
;
133
HcalPFCuts
*
hcalCuts
=
nullptr
;
134
135
edm::ESGetToken<HcalTopology, HcalRecNumberingRecord>
hcalTopologyToken_
;
136
edm::ESGetToken<HcalChannelQuality, HcalChannelQualityRcd>
hcalChannelQualityToken_
;
137
edm::ESGetToken<HcalSeverityLevelComputer, HcalSeverityLevelComputerRcd>
hcalSevLvlComputerToken_
;
138
HcalTopology
*
hcalTopology_
;
139
HcalChannelQuality
*
hcalChStatus_
;
140
HcalSeverityLevelComputer
*
hcalSevLvlComputer_
;
141
143
bool
thePrintTimeReport
;
144
146
double
noiseEcal
(
const
CaloTower
&
tower
)
const
;
147
double
noiseHcal
(
const
CaloTower
&
tower
)
const
;
148
double
noiseHOcal
(
const
CaloTower
&
tower
)
const
;
149
double
noiseRecHit
(
const
DetId
&
detId
)
const
;
150
};
151
152
}
// namespace muonisolation
153
154
#endif
EcalPFRecHitThresholds.h
muonisolation::CaloExtractorByAssociator::noiseHcal
double noiseHcal(const CaloTower &tower) const
Definition:
CaloExtractorByAssociator.cc:445
makeMEIFBenchmarkPlots.ev
ev
Definition:
makeMEIFBenchmarkPlots.py:55
CaloTowerCollection.h
muonisolation::CaloExtractorByAssociator::CaloExtractorByAssociator
CaloExtractorByAssociator()
constructors
Definition:
CaloExtractorByAssociator.h:52
muonisolation::CaloExtractorByAssociator::bFieldToken_
edm::ESGetToken< MagneticField, IdealMagneticFieldRecord > bFieldToken_
Definition:
CaloExtractorByAssociator.h:122
muonisolation::CaloExtractorByAssociator::theThreshold_HO
double theThreshold_HO
Definition:
CaloExtractorByAssociator.h:88
reco::IsoDeposit
Definition:
IsoDeposit.h:49
muonisolation::CaloExtractorByAssociator::hcalSevLvlComputerToken_
edm::ESGetToken< HcalSeverityLevelComputer, HcalSeverityLevelComputerRcd > hcalSevLvlComputerToken_
Definition:
CaloExtractorByAssociator.h:137
muonisolation::CaloExtractorByAssociator::hcalSevLvlComputer_
HcalSeverityLevelComputer * hcalSevLvlComputer_
Definition:
CaloExtractorByAssociator.h:140
muonisolation::CaloExtractorByAssociator::thePropagatorName
std::string thePropagatorName
propagator name to feed into the track associator
Definition:
CaloExtractorByAssociator.h:82
muonisolation::CaloExtractorByAssociator::theVetoCollection
std::vector< DetId > theVetoCollection
Vector of calo Ids to veto – not used.
Definition:
CaloExtractorByAssociator.h:113
muonisolation::CaloExtractorByAssociator::theNoise_HB
double theNoise_HB
Definition:
CaloExtractorByAssociator.h:106
muonisolation::CaloExtractorByAssociator::ecalThresholds
EcalPFRecHitThresholds * ecalThresholds
Definition:
CaloExtractorByAssociator.h:128
muonisolation::CaloExtractorByAssociator::theDepositLabel
std::string theDepositLabel
Label of deposit – suggest to set to "" (all info is in collection name anyways) ...
Definition:
CaloExtractorByAssociator.h:76
muonisolation::CaloExtractorByAssociator::theDR_Max
double theDR_Max
max cone size in which towers are considered
Definition:
CaloExtractorByAssociator.h:100
muonisolation::CaloExtractorByAssociator::hcalChannelQualityToken_
edm::ESGetToken< HcalChannelQuality, HcalChannelQualityRcd > hcalChannelQualityToken_
Definition:
CaloExtractorByAssociator.h:136
HcalTopology
Definition:
HcalTopology.h:26
muonisolation::CaloExtractorByAssociator::noiseRecHit
double noiseRecHit(const DetId &detId) const
Definition:
CaloExtractorByAssociator.cc:455
reco::isodeposit::IsoDepositExtractor
Definition:
IsoDepositExtractor.h:24
muonisolation::CaloExtractorByAssociator
Definition:
CaloExtractorByAssociator.h:49
reco::TrackCollection
std::vector< Track > TrackCollection
collection of Tracks
Definition:
TrackFwd.h:14
muonisolation::CaloExtractorByAssociator::hcalCutsToken_
edm::ESGetToken< HcalPFCuts, HcalPFCutsRcd > hcalCutsToken_
Definition:
CaloExtractorByAssociator.h:131
muonisolation::CaloExtractorByAssociator::theThreshold_H
double theThreshold_H
Definition:
CaloExtractorByAssociator.h:87
muonisolation::CaloExtractorByAssociator::ecalPFRechitThresholdsToken_
edm::ESGetToken< EcalPFRecHitThresholds, EcalPFRecHitThresholdsRcd > ecalPFRechitThresholdsToken_
Definition:
CaloExtractorByAssociator.h:126
muonisolation::CaloExtractorByAssociator::hcalChStatus_
HcalChannelQuality * hcalChStatus_
Definition:
CaloExtractorByAssociator.h:139
muonisolation::CaloExtractorByAssociator::theDepositInstanceLabels
std::vector< std::string > theDepositInstanceLabels
multiple deposits: labels – expect 3 labels beginning with "e", "h", "ho"
Definition:
CaloExtractorByAssociator.h:79
TrackFwd.h
muonisolation::CaloExtractorByAssociator::theDR_Veto_E
double theDR_Veto_E
cone sizes inside which the Et (towers) are not counted
Definition:
CaloExtractorByAssociator.h:93
muonisolation::CaloExtractorByAssociator::theAssociatorParameters
TrackAssociatorParameters * theAssociatorParameters
associator, its' parameters and the propagator
Definition:
CaloExtractorByAssociator.h:119
muonisolation::CaloExtractorByAssociator::theMaxSeverityHE
int theMaxSeverityHE
Definition:
CaloExtractorByAssociator.h:90
muonisolation::CaloExtractorByAssociator::hcalTopology_
HcalTopology * hcalTopology_
Definition:
CaloExtractorByAssociator.h:138
muonisolation::CaloExtractorByAssociator::theDR_Veto_HO
double theDR_Veto_HO
Definition:
CaloExtractorByAssociator.h:95
HLT_2024v14_cff.track
track
Definition:
HLT_2024v14_cff.py:9565
muonisolation::CaloExtractorByAssociator::deposits
std::vector< reco::IsoDeposit > deposits(const edm::Event &ev, const edm::EventSetup &evSetup, const reco::Track &track) const override
return deposits for 3 calorimeter subdetectors (ecal, hcal, ho) – in this order
Definition:
CaloExtractorByAssociator.cc:118
muonisolation::CaloExtractorByAssociator::theThreshold_E
double theThreshold_E
Definition:
CaloExtractorByAssociator.h:86
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
MagneticField.h
muonisolation::CaloExtractorByAssociator::theCenterConeOnCalIntersection
bool theCenterConeOnCalIntersection
Definition:
CaloExtractorByAssociator.h:98
DiMuonV_cfg.tracks
tracks
Definition:
DiMuonV_cfg.py:215
HcalSeverityLevelComputerRcd.h
edm::ESGetToken< MagneticField, IdealMagneticFieldRecord >
HcalPFCutsRcd.h
CaloGeometryRecord.h
muonisolation::CaloExtractorByAssociator::theNoise_EE
double theNoise_EE
Definition:
CaloExtractorByAssociator.h:105
muonisolation::CaloExtractorByAssociator::theNoise_HO
double theNoise_HO
Definition:
CaloExtractorByAssociator.h:108
MuonServiceProxy
Definition:
MuonServiceProxy.h:38
HcalChannelQuality
Definition:
HcalChannelQuality.h:17
muonisolation
Definition:
CandViewExtractor.cc:14
HcalSeverityLevelComputer
Definition:
HcalSeverityLevelComputer.h:24
EcalPFRecHitThresholdsRcd.h
edm::EventSetup
Definition:
EventSetup.h:56
muonisolation::CaloExtractorByAssociator::ecalRecHitThresh_
bool ecalRecHitThresh_
Definition:
CaloExtractorByAssociator.h:127
CaloTower
Definition:
CaloTower.h:26
HcalChannelQualityRcd.h
HcalPFCutsHandler.h
hcalRecHitTable_cff.detId
detId
Definition:
hcalRecHitTable_cff.py:12
HcalChannelQuality.h
muonisolation::CaloExtractorByAssociator::theAssociator
TrackDetectorAssociator * theAssociator
Definition:
CaloExtractorByAssociator.h:120
muonisolation::CaloExtractorByAssociator::theUseEcalRecHitsFlag
bool theUseEcalRecHitsFlag
use towers or rec hits
Definition:
CaloExtractorByAssociator.h:71
DetId
Definition:
DetId.h:17
muonisolation::CaloExtractorByAssociator::theNoise_HE
double theNoise_HE
Definition:
CaloExtractorByAssociator.h:107
CaloGeometry.h
muonisolation::CaloExtractorByAssociator::theNoiseTow_EE
double theNoiseTow_EE
Definition:
CaloExtractorByAssociator.h:110
muonisolation::CaloExtractorByAssociator::theService
MuonServiceProxy * theService
the event setup proxy, it takes care the services update
Definition:
CaloExtractorByAssociator.h:116
muonisolation::CaloExtractorByAssociator::noiseEcal
double noiseEcal(const CaloTower &tower) const
Determine noise for HCAL and ECAL (take some defaults for the time being)
Definition:
CaloExtractorByAssociator.cc:437
muonisolation::CaloExtractorByAssociator::fillVetos
void fillVetos(const edm::Event &ev, const edm::EventSetup &evSetup, const reco::TrackCollection &tracks) override
allows to set extra vetoes (in addition to the muon) – no-op at this point
Definition:
CaloExtractorByAssociator.cc:96
TrackDetectorAssociator
Definition:
TrackDetectorAssociator.h:44
muonisolation::CaloExtractorByAssociator::hcalCuts
HcalPFCuts * hcalCuts
Definition:
CaloExtractorByAssociator.h:133
reco::Track
Definition:
Track.h:27
muonisolation::CaloExtractorByAssociator::theDR_Veto_H
double theDR_Veto_H
Definition:
CaloExtractorByAssociator.h:94
IsoDeposit.h
IsoDepositExtractor.h
HcalPFCuts
Definition:
HcalPFCuts.h:7
muonisolation::CaloExtractorByAssociator::hcalCutsFromDB_
bool hcalCutsFromDB_
Definition:
CaloExtractorByAssociator.h:132
Track.h
edm::ParameterSet
Definition:
ParameterSet.h:48
muonisolation::CaloExtractorByAssociator::theUseHORecHitsFlag
bool theUseHORecHitsFlag
Definition:
CaloExtractorByAssociator.h:73
muonisolation::CaloExtractorByAssociator::hcalTopologyToken_
edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > hcalTopologyToken_
Definition:
CaloExtractorByAssociator.h:135
HcalSeverityLevelComputer.h
muonisolation::CaloExtractorByAssociator::thePrintTimeReport
bool thePrintTimeReport
flag to turn on/off printing of a time report
Definition:
CaloExtractorByAssociator.h:143
muonisolation::CaloExtractorByAssociator::caloGeomToken_
edm::ESGetToken< CaloGeometry, CaloGeometryRecord > caloGeomToken_
Definition:
CaloExtractorByAssociator.h:123
edm::Event
Definition:
Event.h:73
muonisolation::CaloExtractorByAssociator::theNoiseTow_EB
double theNoiseTow_EB
Definition:
CaloExtractorByAssociator.h:109
muonisolation::CaloExtractorByAssociator::noiseHOcal
double noiseHOcal(const CaloTower &tower) const
Definition:
CaloExtractorByAssociator.cc:450
TrackAssociatorParameters
Definition:
TrackAssociatorParameters.h:50
muonisolation::CaloExtractorByAssociator::~CaloExtractorByAssociator
~CaloExtractorByAssociator() override
destructor
Definition:
CaloExtractorByAssociator.cc:87
muonisolation::CaloExtractorByAssociator::theUseHcalRecHitsFlag
bool theUseHcalRecHitsFlag
Definition:
CaloExtractorByAssociator.h:72
ConsumesCollector.h
IdealMagneticFieldRecord.h
EcalCondObjectContainer
Definition:
EcalCondObjectContainer.h:13
muonisolation::CaloExtractorByAssociator::theNoise_EB
double theNoise_EB
Definition:
CaloExtractorByAssociator.h:104
edm::ConsumesCollector
Definition:
ConsumesCollector.h:45
muonisolation::CaloExtractorByAssociator::theMaxSeverityHB
int theMaxSeverityHB
Definition:
CaloExtractorByAssociator.h:89
muonisolation::CaloExtractorByAssociator::deposit
reco::IsoDeposit deposit(const edm::Event &ev, const edm::EventSetup &evSetup, const reco::Track &track) const override
no-op: by design of this extractor the deposits are pulled out all at a time
Definition:
CaloExtractorByAssociator.cc:104
l1tHGCalTowerProducer_cfi.tower
tower
Definition:
l1tHGCalTowerProducer_cfi.py:4
GlobalPoint.h
HcalTopology.h
Generated for CMSSW Reference Manual by
1.8.14