CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Attributes
HcalPFClusterIsolation< T1 > Class Template Reference

#include <HcalPFClusterIsolation.h>

Public Types

typedef std::vector< T1 > T1Collection
 
typedef edm::Ref< T1CollectionT1Ref
 

Public Member Functions

double getSum (const T1Ref candRef, const std::vector< edm::Handle< reco::PFClusterCollection >> &clusterHandles)
 
 HcalPFClusterIsolation (double drMax, double drVetoBarrel, double drVetoEndcap, double etaStripBarrel, double etaStripEndcap, double energyBarrel, double energyEndcap, bool useEt)
 
 ~HcalPFClusterIsolation ()
 

Private Attributes

const double drMax_
 
const double drVetoBarrel_
 
const double drVetoEndcap_
 
const double energyBarrel_
 
const double energyEndcap_
 
const double etaStripBarrel_
 
const double etaStripEndcap_
 
const bool useEt_
 

Detailed Description

template<typename T1>
class HcalPFClusterIsolation< T1 >

Definition at line 17 of file HcalPFClusterIsolation.h.

Member Typedef Documentation

◆ T1Collection

template<typename T1>
typedef std::vector<T1> HcalPFClusterIsolation< T1 >::T1Collection

Definition at line 19 of file HcalPFClusterIsolation.h.

◆ T1Ref

template<typename T1>
typedef edm::Ref<T1Collection> HcalPFClusterIsolation< T1 >::T1Ref

Definition at line 20 of file HcalPFClusterIsolation.h.

Constructor & Destructor Documentation

◆ HcalPFClusterIsolation()

template<typename T1 >
HcalPFClusterIsolation< T1 >::HcalPFClusterIsolation ( double  drMax,
double  drVetoBarrel,
double  drVetoEndcap,
double  etaStripBarrel,
double  etaStripEndcap,
double  energyBarrel,
double  energyEndcap,
bool  useEt 
)

◆ ~HcalPFClusterIsolation()

template<typename T1 >
HcalPFClusterIsolation< T1 >::~HcalPFClusterIsolation ( )

Definition at line 29 of file HcalPFClusterIsolation.cc.

29 {}

Member Function Documentation

◆ getSum()

template<typename T1 >
double HcalPFClusterIsolation< T1 >::getSum ( const T1Ref  candRef,
const std::vector< edm::Handle< reco::PFClusterCollection >> &  clusterHandles 
)

Definition at line 32 of file HcalPFClusterIsolation.cc.

33  {
34  double etSum = 0.;
35 
36  float etaStrip = 0;
37  float dRVeto = 0;
38  if (fabs(candRef->eta()) < 1.479) {
39  dRVeto = drVetoBarrel_;
40  etaStrip = etaStripBarrel_;
41  } else {
42  dRVeto = drVetoEndcap_;
43  etaStrip = etaStripEndcap_;
44  }
45 
46  for (unsigned int nHandle = 0; nHandle < clusterHandles.size(); nHandle++) {
47  for (unsigned i = 0; i < clusterHandles[nHandle]->size(); i++) {
48  const reco::PFClusterRef pfclu(clusterHandles[nHandle], i);
49 
50  if (fabs(candRef->eta()) < 1.479) {
51  if (fabs(pfclu->pt()) < energyBarrel_)
52  continue;
53  } else {
54  if (fabs(pfclu->energy()) < energyEndcap_)
55  continue;
56  }
57 
58  float dEta = fabs(candRef->eta() - pfclu->eta());
59  if (dEta < etaStrip)
60  continue;
61 
62  float dR = deltaR(candRef->eta(), candRef->phi(), pfclu->eta(), pfclu->phi());
63  if (dR > drMax_ || dR < dRVeto)
64  continue;
65 
66  if (useEt_)
67  etSum += pfclu->pt();
68  else
69  etSum += pfclu->energy();
70  }
71  }
72 
73  return etSum;
74 }

References PbPb_ZMuSkimMuonDPG_cff::deltaR, HLT_2018_cff::dEta, HGC3DClusterGenMatchSelector_cfi::dR, and mps_fire::i.

Referenced by EgammaHcalPFClusterIsolationProducer< T1 >::produce(), and HLTHcalPFClusterIsolationProducer< T1 >::produce().

Member Data Documentation

◆ drMax_

template<typename T1>
const double HcalPFClusterIsolation< T1 >::drMax_
private

Definition at line 35 of file HcalPFClusterIsolation.h.

◆ drVetoBarrel_

template<typename T1>
const double HcalPFClusterIsolation< T1 >::drVetoBarrel_
private

Definition at line 36 of file HcalPFClusterIsolation.h.

◆ drVetoEndcap_

template<typename T1>
const double HcalPFClusterIsolation< T1 >::drVetoEndcap_
private

Definition at line 37 of file HcalPFClusterIsolation.h.

◆ energyBarrel_

template<typename T1>
const double HcalPFClusterIsolation< T1 >::energyBarrel_
private

Definition at line 40 of file HcalPFClusterIsolation.h.

◆ energyEndcap_

template<typename T1>
const double HcalPFClusterIsolation< T1 >::energyEndcap_
private

Definition at line 41 of file HcalPFClusterIsolation.h.

◆ etaStripBarrel_

template<typename T1>
const double HcalPFClusterIsolation< T1 >::etaStripBarrel_
private

Definition at line 38 of file HcalPFClusterIsolation.h.

◆ etaStripEndcap_

template<typename T1>
const double HcalPFClusterIsolation< T1 >::etaStripEndcap_
private

Definition at line 39 of file HcalPFClusterIsolation.h.

◆ useEt_

template<typename T1>
const bool HcalPFClusterIsolation< T1 >::useEt_
private

Definition at line 42 of file HcalPFClusterIsolation.h.

HLT_2018_cff.etaStripEndcap
etaStripEndcap
Definition: HLT_2018_cff.py:17512
mps_fire.i
i
Definition: mps_fire.py:355
HcalPFClusterIsolation::useEt_
const bool useEt_
Definition: HcalPFClusterIsolation.h:42
HLT_2018_cff.dEta
dEta
Definition: HLT_2018_cff.py:12289
edm::Ref< PFClusterCollection >
HLT_2018_cff.drMax
drMax
Definition: HLT_2018_cff.py:17514
HcalPFClusterIsolation::energyBarrel_
const double energyBarrel_
Definition: HcalPFClusterIsolation.h:40
HcalPFClusterIsolation::etaStripBarrel_
const double etaStripBarrel_
Definition: HcalPFClusterIsolation.h:38
HLT_2018_cff.useEt
useEt
Definition: HLT_2018_cff.py:13608
PbPb_ZMuSkimMuonDPG_cff.deltaR
deltaR
Definition: PbPb_ZMuSkimMuonDPG_cff.py:63
HLT_2018_cff.drVetoBarrel
drVetoBarrel
Definition: HLT_2018_cff.py:17513
HcalPFClusterIsolation::etaStripEndcap_
const double etaStripEndcap_
Definition: HcalPFClusterIsolation.h:39
HLT_2018_cff.drVetoEndcap
drVetoEndcap
Definition: HLT_2018_cff.py:17517
HcalPFClusterIsolation::drMax_
const double drMax_
Definition: HcalPFClusterIsolation.h:35
HLT_2018_cff.energyBarrel
energyBarrel
Definition: HLT_2018_cff.py:17515
HcalPFClusterIsolation::energyEndcap_
const double energyEndcap_
Definition: HcalPFClusterIsolation.h:41
HcalPFClusterIsolation::drVetoBarrel_
const double drVetoBarrel_
Definition: HcalPFClusterIsolation.h:36
HcalPFClusterIsolation::drVetoEndcap_
const double drVetoEndcap_
Definition: HcalPFClusterIsolation.h:37
HLT_2018_cff.energyEndcap
energyEndcap
Definition: HLT_2018_cff.py:17509
HLT_2018_cff.etaStripBarrel
etaStripBarrel
Definition: HLT_2018_cff.py:17508
HGC3DClusterGenMatchSelector_cfi.dR
dR
Definition: HGC3DClusterGenMatchSelector_cfi.py:7