Main Page
Namespaces
Classes
Package Documentation
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Pages
RecoEgamma
EgammaIsolationAlgos
plugins
EgammaTowerExtractor.h
Go to the documentation of this file.
1
#ifndef EgammaTowerIsolation_h
2
#define EgammaTowerIsolation_h
3
4
//*****************************************************************************
5
// File: EgammaTowerExtractor.h
6
// ----------------------------------------------------------------------------
7
// OrigAuth: Matthias Mozer
8
// Institute: IIHE-VUB
9
//=============================================================================
10
//*****************************************************************************
11
12
//C++ includes
13
#include <vector>
14
#include <functional>
15
16
//CMSSW includes
17
#include "
DataFormats/Candidate/interface/Candidate.h
"
18
#include "
DataFormats/CaloTowers/interface/CaloTowerCollection.h
"
19
20
#include "
FWCore/Framework/interface/Event.h
"
21
#include "
FWCore/Framework/interface/EventSetup.h
"
22
#include "
FWCore/Framework/interface/ConsumesCollector.h
"
23
#include "
FWCore/ParameterSet/interface/ParameterSet.h
"
24
#include "
FWCore/Utilities/interface/InputTag.h
"
25
26
#include "
DataFormats/TrackReco/interface/Track.h
"
27
#include "
DataFormats/TrackReco/interface/TrackFwd.h
"
28
29
#include "
PhysicsTools/IsolationAlgos/interface/IsoDepositExtractor.h
"
30
#include "
DataFormats/RecoCandidate/interface/IsoDeposit.h
"
31
32
33
namespace
egammaisolation {
34
35
class
EgammaTowerExtractor
:
public
reco::isodeposit::IsoDepositExtractor
{
36
37
public
:
38
enum
HcalDepth
{
AllDepths
=-1,
Undefined
=0,
Depth1
=1,
Depth2
=2};
39
40
41
public
:
42
EgammaTowerExtractor
(
const
edm::ParameterSet
& par,
edm::ConsumesCollector
&& iC ) :
43
EgammaTowerExtractor
(par, iC) {}
44
EgammaTowerExtractor
(
const
edm::ParameterSet
& par,
edm::ConsumesCollector
& iC ) :
45
extRadius2_
(par.getParameter<double>(
"extRadius"
)),
46
intRadius_
(par.getParameter<double>(
"intRadius"
)),
47
etLow_
(par.getParameter<double>(
"etMin"
)),
48
caloTowerToken
(iC.consumes<
CaloTowerCollection
>(par.getParameter<edm::
InputTag
>(
"caloTowers"
))),
49
depth_
(par.getParameter<int>(
"hcalDepth"
))
50
{
51
extRadius2_
*=
extRadius2_
;
52
//lets just check we have a valid depth
53
//should we throw an exception or just warn and then fail gracefully later?
54
if
(
depth_
!=
AllDepths
&&
depth_
!=
Depth1
&&
depth_
!=
Depth2
){
55
throw
cms::Exception
(
"Configuration Error"
) <<
"hcalDepth passed to EgammaTowerExtractor is invalid "
<<std::endl;
56
}
57
}
58
59
virtual
~EgammaTowerExtractor
() ;
60
61
virtual
void
fillVetos
(
const
edm::Event
&
ev
,
const
edm::EventSetup
& evSetup,
62
const
reco::TrackCollection
&
tracks
) { }
63
virtual
reco::IsoDeposit
deposit
(
const
edm::Event
&
ev
,
const
edm::EventSetup
& evSetup,
64
const
reco::Track
& track)
const
{
65
throw
cms::Exception
(
"Configuration Error"
) <<
66
"This extractor "
<< (
typeid
(
this
).
name
()) <<
" is not made for tracks"
;
67
}
68
virtual
reco::IsoDeposit
deposit
(
const
edm::Event
&
ev
,
const
edm::EventSetup
& evSetup,
69
const
reco::Candidate
&
c
)
const
;
70
71
private
:
72
double
extRadius2_
;
73
double
intRadius_
;
74
double
etLow_
;
75
76
77
edm::EDGetTokenT<CaloTowerCollection>
caloTowerToken
;
78
int
depth_
;
79
//const CaloTowerCollection *towercollection_ ;
80
};
81
}
82
#endif
CaloTowerCollection.h
reco::IsoDeposit
Definition:
IsoDeposit.h:46
edm::SortedCollection< CaloTower >
egammaisolation::EgammaTowerExtractor::Depth1
Definition:
EgammaTowerExtractor.h:38
egammaisolation::EgammaTowerExtractor::AllDepths
Definition:
EgammaTowerExtractor.h:38
egammaisolation::EgammaTowerExtractor::depth_
int depth_
Definition:
EgammaTowerExtractor.h:78
Event.h
egammaisolation::EgammaTowerExtractor::deposit
virtual reco::IsoDeposit deposit(const edm::Event &ev, const edm::EventSetup &evSetup, const reco::Track &track) const
Definition:
EgammaTowerExtractor.h:63
EventSetup.h
reco::Candidate
Definition:
Candidate.h:28
reco::isodeposit::IsoDepositExtractor
Definition:
IsoDepositExtractor.h:25
reco::TrackCollection
std::vector< Track > TrackCollection
collection of Tracks
Definition:
TrackFwd.h:13
egammaisolation::EgammaTowerExtractor::~EgammaTowerExtractor
virtual ~EgammaTowerExtractor()
Definition:
EgammaTowerExtractor.cc:31
ev
bool ev
Definition:
Hydjet2Hadronizer.cc:90
TrackFwd.h
egammaisolation::EgammaTowerExtractor::HcalDepth
HcalDepth
Definition:
EgammaTowerExtractor.h:38
EnergyCorrector.c
tuple c
Definition:
EnergyCorrector.py:43
mergeVDriftHistosByStation.name
string name
Definition:
mergeVDriftHistosByStation.py:77
HLT_25ns14e33_v1_cff.InputTag
tuple InputTag
Definition:
HLT_25ns14e33_v1_cff.py:45333
edm::EDGetTokenT
Definition:
EDGetToken.h:32
ParameterSet.h
Candidate.h
egammaisolation::EgammaTowerExtractor::Undefined
Definition:
EgammaTowerExtractor.h:38
egammaisolation::EgammaTowerExtractor::fillVetos
virtual void fillVetos(const edm::Event &ev, const edm::EventSetup &evSetup, const reco::TrackCollection &tracks)
Definition:
EgammaTowerExtractor.h:61
egammaisolation::EgammaTowerExtractor::extRadius2_
double extRadius2_
Definition:
EgammaTowerExtractor.h:72
egammaisolation::EgammaTowerExtractor::EgammaTowerExtractor
EgammaTowerExtractor(const edm::ParameterSet &par, edm::ConsumesCollector &&iC)
Definition:
EgammaTowerExtractor.h:42
egammaisolation::EgammaTowerExtractor::Depth2
Definition:
EgammaTowerExtractor.h:38
edm::EventSetup
Definition:
EventSetup.h:44
egammaisolation::EgammaTowerExtractor::EgammaTowerExtractor
EgammaTowerExtractor(const edm::ParameterSet &par, edm::ConsumesCollector &iC)
Definition:
EgammaTowerExtractor.h:44
egammaisolation::EgammaTowerExtractor
Definition:
EgammaTowerExtractor.h:35
edm::hlt::Exception
error
Definition:
HLTenums.h:21
egammaisolation::EgammaTowerExtractor::intRadius_
double intRadius_
Definition:
EgammaTowerExtractor.h:73
testEve_cfg.tracks
tuple tracks
Definition:
testEve_cfg.py:39
reco::Track
Definition:
Track.h:28
IsoDeposit.h
IsoDepositExtractor.h
InputTag.h
egammaisolation::EgammaTowerExtractor::etLow_
double etLow_
Definition:
EgammaTowerExtractor.h:74
egammaisolation::EgammaTowerExtractor::caloTowerToken
edm::EDGetTokenT< CaloTowerCollection > caloTowerToken
Definition:
EgammaTowerExtractor.h:77
edm::ParameterSet
Definition:
ParameterSet.h:35
edm::Event
Definition:
Event.h:59
Track.h
ConsumesCollector.h
edm::ConsumesCollector
Definition:
ConsumesCollector.h:32
Generated for CMSSW Reference Manual by
1.8.5