ElectronPFIsolationWithMapBasedVeto::ElectronPFIsolationWithMapBasedVeto |
( |
const edm::ParameterSet & |
c | ) |
|
|
inline |
ElectronPFIsolationWithMapBasedVeto::~ElectronPFIsolationWithMapBasedVeto |
( |
| ) |
|
|
inlineoverride |
void ElectronPFIsolationWithMapBasedVeto::getEventInfo |
( |
const edm::Event & |
iEvent | ) |
|
|
inlineoverridevirtual |
Implements citk::IsolationConeDefinitionBase.
Definition at line 110 of file ElectronPFIsolationWithMapBasedVeto.cc.
References pat::Electron::associatedPackedPFCandidates(), reco::deltaR2(), Exception, edm::Ptr< T >::get(), and mps_fire::result.
118 bool inFootprint =
false;
120 const float deltar2 =
124 if (aspacked.get()) {
125 inFootprint = isInFootprint(aspat_electronptr->associatedPackedPFCandidates(), aspacked);
128 if (aspacked->charge() != 0) {
129 bool is_vertex_allowed =
false;
131 if (vtxtype == aspacked->fromPV()) {
132 is_vertex_allowed =
true;
137 result &= (is_vertex_allowed);
140 result &= deltar2 <
_coneSize2 && (!inFootprint);
144 else if (aspf.get()) {
147 result &= deltar2 <
_coneSize2 && (!inFootprint);
152 throw cms::Exception(
"InvalidIsolationInput") <<
"The supplied candidate to be used as isolation " 153 <<
"was neither a reco::Photon nor a pat::Photon!";
const std::vector< unsigned > _miniAODVertexCodes
edm::Handle< edm::ValueMap< std::vector< reco::PFCandidateRef > > > particleBasedIsolationMap
constexpr auto deltaR2(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
const std::string ElectronPFIsolationWithMapBasedVeto::_isolateAgainst |
|
private |
const std::vector<unsigned> ElectronPFIsolationWithMapBasedVeto::_miniAODVertexCodes |
|
private |
const edm::InputTag ElectronPFIsolationWithMapBasedVeto::_particleBasedIsolation |
|
private |
const std::string ElectronPFIsolationWithMapBasedVeto::_vertexCollection |
|
private |