CMS 3D CMS Logo

List of all members | Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes
FFTJetPFPileupCleaner Class Reference

#include <RecoJets/FFTJetProducers/plugins/FFTJetPFPileupCleaner.cc>

Inheritance diagram for FFTJetPFPileupCleaner:
edm::EDProducer edm::ProducerBase edm::EDConsumerBase edm::ProductRegistryHelper

Public Member Functions

 FFTJetPFPileupCleaner (const edm::ParameterSet &)
 
 ~FFTJetPFPileupCleaner () override
 
- Public Member Functions inherited from edm::EDProducer
 EDProducer ()
 
SerialTaskQueueglobalLuminosityBlocksQueue ()
 
SerialTaskQueueglobalRunsQueue ()
 
ModuleDescription const & moduleDescription () const
 
 ~EDProducer () override
 
- Public Member Functions inherited from edm::ProducerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
std::vector< edm::ProductResolverIndex > const & indiciesForPutProducts (BranchType iBranchType) const
 
 ProducerBase ()
 
std::vector< edm::ProductResolverIndex > const & putTokenIndexToProductResolverIndex () const
 
std::vector< bool > const & recordProvenanceList () const
 
void registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &)
 
std::function< void(BranchDescription const &)> registrationCallback () const
 used by the fwk to register list of products More...
 
void resolvePutIndicies (BranchType iBranchType, ModuleToResolverIndicies const &iIndicies, std::string const &moduleLabel)
 
TypeLabelList const & typeLabelList () const
 used by the fwk to register the list of products of this module More...
 
 ~ProducerBase () noexcept(false) override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase &&)=default
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
ESProxyIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESProxyIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex > const & esGetTokenRecordIndicesVector (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector< ProductResolverIndexAndSkipBit > const & itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Protected Member Functions

void beginJob () override
 
void endJob () override
 
void produce (edm::Event &, const edm::EventSetup &) override
 
- Protected Member Functions inherited from edm::ProducerBase
template<class ProductType >
BranchAliasSetterT< ProductType > produces ()
 declare what type of product will make and with which optional label More...
 
template<typename ProductType , BranchType B>
BranchAliasSetterT< ProductType > produces ()
 
template<typename ProductType , Transition B>
BranchAliasSetterT< ProductType > produces ()
 
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
template<BranchType B>
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
template<Transition B>
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
template<typename ProductType , Transition B>
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
template<class ProductType >
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
template<typename ProductType , BranchType B>
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
ProducesCollector producesCollector ()
 
- Protected Member Functions inherited from edm::EDConsumerBase
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B = InEvent>
EDConsumerBaseAdaptor< B > consumes (edm::InputTag tag) noexcept
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<Transition Tr = Transition::Event>
constexpr auto esConsumes () noexcept
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag) noexcept
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 

Private Member Functions

void buildRemovalMask ()
 
 FFTJetPFPileupCleaner ()=delete
 
 FFTJetPFPileupCleaner (const FFTJetPFPileupCleaner &)=delete
 
reco::VertexRef findSomeVertexWFakes (const edm::Handle< reco::VertexCollection > &vertices, const edm::Handle< reco::VertexCollection > &fakeVertices, const reco::PFCandidate &pfcand, bool *fromFakeSet) const
 
bool isAcceptableVtx (reco::VertexCollection::const_iterator iv) const
 
bool isRemovable (reco::PFCandidate::ParticleType ptype) const
 
FFTJetPFPileupCleaneroperator= (const FFTJetPFPileupCleaner &)=delete
 
void setRemovalBit (reco::PFCandidate::ParticleType ptype, bool onOff)
 

Private Attributes

bool checkClosestZVertex
 
double etaMax
 
double etaMin
 
edm::InputTag FakePrimaryVertices
 
edm::EDGetTokenT< reco::VertexCollectionFakePrimaryVerticesToken
 
bool keepIfPVneighbor
 
edm::InputTag PFCandidates
 
edm::EDGetTokenT< reco::PFCandidateCollectionPFCandidatesToken
 
unsigned removalMask
 
bool remove_e
 
bool remove_egamma_HF
 
bool remove_gamma
 
bool remove_h
 
bool remove_h0
 
bool remove_h_HF
 
bool remove_mu
 
bool remove_X
 
bool removeMainVertex
 
bool removeUnassociated
 
bool reverseRemovalDecision
 
bool useFakePrimaryVertex
 
double vertexNdofCut
 
double vertexRhoCut
 
double vertexZmaxCut
 
edm::InputTag Vertices
 
edm::EDGetTokenT< reco::VertexCollectionVerticesToken
 
std::vector< std::pair< double, unsigned > > zAssoc
 

Additional Inherited Members

- Public Types inherited from edm::EDProducer
typedef EDProducer ModuleType
 
- Public Types inherited from edm::ProducerBase
using ModuleToResolverIndicies = std::unordered_multimap< std::string, std::tuple< edm::TypeID const *, const char *, edm::ProductResolverIndex > >
 
typedef ProductRegistryHelper::TypeLabelList TypeLabelList
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::EDProducer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 
static bool wantsGlobalLuminosityBlocks ()
 
static bool wantsGlobalRuns ()
 
static bool wantsInputProcessBlocks ()
 
static bool wantsProcessBlocks ()
 
static bool wantsStreamLuminosityBlocks ()
 
static bool wantsStreamRuns ()
 

Detailed Description

Description: cleans up a collection of partice flow objects

Implementation: [Notes on implementation]

Definition at line 45 of file FFTJetPFPileupCleaner.cc.

Constructor & Destructor Documentation

◆ FFTJetPFPileupCleaner() [1/3]

FFTJetPFPileupCleaner::FFTJetPFPileupCleaner ( const edm::ParameterSet ps)
explicit

Definition at line 139 of file FFTJetPFPileupCleaner.cc.

149  init_param(bool, remove_X),
150  init_param(bool, remove_h),
151  init_param(bool, remove_e),
152  init_param(bool, remove_mu),
153  init_param(bool, remove_gamma),
154  init_param(bool, remove_h0),
155  init_param(bool, remove_h_HF),
157  removalMask(0),
158  init_param(double, etaMin),
159  init_param(double, etaMax),
160  init_param(double, vertexNdofCut),
161  init_param(double, vertexZmaxCut),
162  init_param(double, vertexRhoCut) {
164 
165  PFCandidatesToken = consumes<reco::PFCandidateCollection>(PFCandidates);
166  VerticesToken = consumes<reco::VertexCollection>(Vertices);
168  FakePrimaryVerticesToken = consumes<reco::VertexCollection>(FakePrimaryVertices);
169 
170  produces<reco::PFCandidateCollection>();
171 }

References buildRemovalMask(), FakePrimaryVertices, FakePrimaryVerticesToken, PFCandidates, PFCandidatesToken, useFakePrimaryVertex, Vertices, and VerticesToken.

◆ ~FFTJetPFPileupCleaner()

FFTJetPFPileupCleaner::~FFTJetPFPileupCleaner ( )
override

Definition at line 173 of file FFTJetPFPileupCleaner.cc.

173 {}

◆ FFTJetPFPileupCleaner() [2/3]

FFTJetPFPileupCleaner::FFTJetPFPileupCleaner ( )
privatedelete

◆ FFTJetPFPileupCleaner() [3/3]

FFTJetPFPileupCleaner::FFTJetPFPileupCleaner ( const FFTJetPFPileupCleaner )
privatedelete

Member Function Documentation

◆ beginJob()

void FFTJetPFPileupCleaner::beginJob ( void  )
overrideprotectedvirtual

Reimplemented from edm::EDProducer.

Definition at line 450 of file FFTJetPFPileupCleaner.cc.

450 {}

◆ buildRemovalMask()

void FFTJetPFPileupCleaner::buildRemovalMask ( )
private

◆ endJob()

void FFTJetPFPileupCleaner::endJob ( void  )
overrideprotectedvirtual

Reimplemented from edm::EDProducer.

Definition at line 453 of file FFTJetPFPileupCleaner.cc.

453 {}

◆ findSomeVertexWFakes()

reco::VertexRef FFTJetPFPileupCleaner::findSomeVertexWFakes ( const edm::Handle< reco::VertexCollection > &  vertices,
const edm::Handle< reco::VertexCollection > &  fakeVertices,
const reco::PFCandidate pfcand,
bool *  fromFakeSet 
) const
private

Definition at line 263 of file FFTJetPFPileupCleaner.cc.

266  {
267  typedef reco::VertexCollection::const_iterator IV;
269 
270  *fromFakeSet = false;
271  reco::TrackBaseRef trackBaseRef(pfcand.trackRef());
272 
273  size_t iVertex = 0;
274  unsigned nFoundVertex = 0;
275  const IV vertend(vertices->end());
276 
277  {
278  unsigned index = 0;
279  double bestweight = 0.0;
280  for (IV iv = vertices->begin(); iv != vertend; ++iv, ++index)
281  if (isAcceptableVtx(iv)) {
282  const reco::Vertex& vtx = *iv;
283 
284  // loop on tracks in vertices
285  IT trackend(vtx.tracks_end());
286  for (IT iTrack = vtx.tracks_begin(); iTrack != trackend; ++iTrack) {
287  const reco::TrackBaseRef& baseRef = *iTrack;
288 
289  // one of the tracks in the vertex is the same as
290  // the track considered in the function
291  if (baseRef == trackBaseRef) {
292  // select the vertex for which the track has the highest weight
293  const double w = vtx.trackWeight(baseRef);
294  if (w > bestweight) {
295  bestweight = w;
296  iVertex = index;
297  nFoundVertex++;
298  }
299  }
300  }
301  }
302  }
303 
304  if (nFoundVertex > 0) {
305  if (nFoundVertex != 1)
306  edm::LogWarning("TrackOnTwoVertex") << "a track is shared by at least two vertices. "
307  << "Used to be an assert";
308 
309  // Check if we can re-associate this track with one
310  // of the fake vertices
311  if (useFakePrimaryVertex) {
312  const double ztrack = pfcand.vertex().z();
313  double dzmin = std::abs(ztrack - ((*vertices)[iVertex]).z());
314 
315  const IV fakeEnd(fakeVertices->end());
316  unsigned index = 0;
317  for (IV iv = fakeVertices->begin(); iv != fakeEnd; ++iv, ++index)
318  if (isAcceptableVtx(iv)) {
319  const double dz = std::abs(ztrack - iv->z());
320  if (dz < dzmin) {
321  dzmin = dz;
322  iVertex = index;
323  *fromFakeSet = true;
324  }
325  }
326  }
327 
328  return reco::VertexRef(*fromFakeSet ? fakeVertices : vertices, iVertex);
329  }
330 
331  // optional: as a secondary solution, associate the closest vertex in z
332  if (checkClosestZVertex) {
333  const double ztrack = pfcand.vertex().z();
334  bool foundVertex = false;
335 
336  if (keepIfPVneighbor) {
337  // Sort all vertices according to their Z coordinate
338  zAssoc.clear();
339  unsigned index = 0;
340  for (IV iv = vertices->begin(); iv != vertend; ++iv, ++index)
341  if (isAcceptableVtx(iv))
342  zAssoc.push_back(std::pair<double, unsigned>(iv->z(), index));
343  const unsigned numRealVertices = index;
344 
345  // Mix the fake vertex collection into zAssoc.
346  // Note that we do not reset "index" before doing this.
347  if (useFakePrimaryVertex) {
348  const IV fakeEnd(fakeVertices->end());
349  for (IV iv = fakeVertices->begin(); iv != fakeEnd; ++iv, ++index)
350  if (isAcceptableVtx(iv))
351  zAssoc.push_back(std::pair<double, unsigned>(iv->z(), index));
352  }
353 
354  // Check where the track z position fits into this sequence
355  if (!zAssoc.empty()) {
356  std::sort(zAssoc.begin(), zAssoc.end());
357  std::pair<double, unsigned> tPair(ztrack, UINT_MAX);
358  const unsigned iAbove = std::upper_bound(zAssoc.begin(), zAssoc.end(), tPair) - zAssoc.begin();
359 
360  // Check whether one of the vertices with indices
361  // iAbove or (iAbove - 1) is a primary vertex.
362  // If so, return it. Otherwise return the one
363  // with closest distance to the track.
364  unsigned ich[2] = {0U, 0U};
365  unsigned nch = 1;
366  if (iAbove) {
367  ich[0] = iAbove - 1U;
368  ich[1] = iAbove;
369  if (iAbove < zAssoc.size())
370  nch = 2;
371  }
372 
373  double dzmin = 1.0e100;
374  unsigned bestVertexNum = UINT_MAX;
375  for (unsigned icheck = 0; icheck < nch; ++icheck) {
376  const unsigned zAssocIndex = ich[icheck];
377  const unsigned vertexNum = zAssoc[zAssocIndex].second;
378 
379  if (vertexNum == numRealVertices || (!useFakePrimaryVertex && vertexNum == 0U)) {
380  bestVertexNum = vertexNum;
381  break;
382  }
383 
384  const double dz = std::abs(ztrack - zAssoc[zAssocIndex].first);
385  if (dz < dzmin) {
386  dzmin = dz;
387  bestVertexNum = vertexNum;
388  }
389  }
390 
391  foundVertex = bestVertexNum < UINT_MAX;
392  if (foundVertex) {
393  iVertex = bestVertexNum;
394  if (iVertex >= numRealVertices) {
395  *fromFakeSet = true;
396  iVertex -= numRealVertices;
397  }
398  }
399  }
400  } else {
401  // This is a simple association algorithm (from PFPileUp)
402  // extended to take fake vertices into account
403  double dzmin = 1.0e100;
404  unsigned index = 0;
405  for (IV iv = vertices->begin(); iv != vertend; ++iv, ++index)
406  if (isAcceptableVtx(iv)) {
407  const double dz = std::abs(ztrack - iv->z());
408  if (dz < dzmin) {
409  dzmin = dz;
410  iVertex = index;
411  foundVertex = true;
412  }
413  }
414 
415  if (useFakePrimaryVertex) {
416  const IV fakeEnd(fakeVertices->end());
417  index = 0;
418  for (IV iv = fakeVertices->begin(); iv != fakeEnd; ++iv, ++index)
419  if (isAcceptableVtx(iv)) {
420  const double dz = std::abs(ztrack - iv->z());
421  if (dz < dzmin) {
422  dzmin = dz;
423  iVertex = index;
424  *fromFakeSet = true;
425  foundVertex = true;
426  }
427  }
428  }
429  }
430 
431  if (foundVertex)
432  return reco::VertexRef(*fromFakeSet ? fakeVertices : vertices, iVertex);
433  }
434 
435  return reco::VertexRef();
436 }

References funct::abs(), checkClosestZVertex, PVValHelper::dz, dqmdumpme::first, isAcceptableVtx(), keepIfPVneighbor, pfDeepBoostedJetPreprocessParams_cfi::pfcand, mitigatedMETSequence_cff::U, pfDeepBoostedJetPreprocessParams_cfi::upper_bound, useFakePrimaryVertex, pwdgSkimBPark_cfi::vertices, extraflags_cff::vtx, w, z, and zAssoc.

Referenced by produce().

◆ isAcceptableVtx()

bool FFTJetPFPileupCleaner::isAcceptableVtx ( reco::VertexCollection::const_iterator  iv) const
private

Definition at line 175 of file FFTJetPFPileupCleaner.cc.

175  {
176  return !iv->isFake() && static_cast<double>(iv->ndof()) > vertexNdofCut && std::abs(iv->z()) < vertexZmaxCut &&
177  iv->position().rho() < vertexRhoCut;
178 }

References funct::abs(), vertexNdofCut, vertexRhoCut, and vertexZmaxCut.

Referenced by findSomeVertexWFakes().

◆ isRemovable()

bool FFTJetPFPileupCleaner::isRemovable ( reco::PFCandidate::ParticleType  ptype) const
private

Definition at line 244 of file FFTJetPFPileupCleaner.cc.

244  {
245  const unsigned shift = static_cast<unsigned>(ptype);
246  assert(shift < 32U);
247  return removalMask & (1U << shift);
248 }

References cms::cuda::assert(), OfflineHarvestingSequence_cosmic::ptype, removalMask, edm::shift, and mitigatedMETSequence_cff::U.

Referenced by produce().

◆ operator=()

FFTJetPFPileupCleaner& FFTJetPFPileupCleaner::operator= ( const FFTJetPFPileupCleaner )
privatedelete

◆ produce()

void FFTJetPFPileupCleaner::produce ( edm::Event iEvent,
const edm::EventSetup iSetup 
)
overrideprotectedvirtual

Implements edm::EDProducer.

Definition at line 181 of file FFTJetPFPileupCleaner.cc.

181  {
182  // get PFCandidates
183  auto pOutput = std::make_unique<reco::PFCandidateCollection>();
184 
187 
188  // get vertices
190  iEvent.getByToken(VerticesToken, vertices);
191 
193  if (useFakePrimaryVertex) {
194  iEvent.getByToken(FakePrimaryVerticesToken, fakeVertices);
195  if (!fakeVertices.isValid())
196  throw cms::Exception("FFTJetBadConfig") << "ERROR in FFTJetPFPileupCleaner:"
197  " could not find fake vertices"
198  << std::endl;
199  }
200 
201  const unsigned ncand = pfCandidates->size();
202  for (unsigned i = 0; i < ncand; ++i) {
204  bool remove = false;
205 
206  if (isRemovable(candptr->particleId())) {
207  bool fromFakeSet = false;
208  reco::VertexRef vertexref(findSomeVertexWFakes(vertices, fakeVertices, *candptr, &fromFakeSet));
209  if (vertexref.isNull()) {
210  // Track is not associated with any vertex
211  // in any of the vertex sets
213  } else if (vertexref.key() == 0 && (!useFakePrimaryVertex || fromFakeSet)) {
214  // Track is associated with the main primary vertex
215  // However, if we are using fake vertices, this only
216  // matters if the vertex comes from the fake set. If
217  // it comes from the real set, remove the track anyway
218  // because in the combined set the associated vertex
219  // would not be the main primary vertex.
221  } else
222  remove = true;
223  }
224 
225  // Check the eta range
226  if (!remove) {
227  const double eta = candptr->p4().Eta();
228  remove = eta < etaMin || eta > etaMax;
229  }
230 
231  // Should we remember this candidate?
233  remove = !remove;
234  if (!remove) {
235  const reco::PFCandidate& cand = (*pfCandidates)[i];
236  pOutput->push_back(cand);
237  pOutput->back().setSourceCandidatePtr(candptr);
238  }
239  }
240 
241  iEvent.put(std::move(pOutput));
242 }

References PVValHelper::eta, etaMax, FakePrimaryVerticesToken, findSomeVertexWFakes(), mps_fire::i, iEvent, edm::Ref< C, T, F >::isNull(), isRemovable(), edm::HandleBase::isValid(), edm::Ref< C, T, F >::key(), eostools::move(), zmumugammaAnalyzer_cfi::pfCandidates, PFCandidatesToken, MatrixUtil::remove(), removeMainVertex, removeUnassociated, reverseRemovalDecision, useFakePrimaryVertex, pwdgSkimBPark_cfi::vertices, and VerticesToken.

◆ setRemovalBit()

void FFTJetPFPileupCleaner::setRemovalBit ( reco::PFCandidate::ParticleType  ptype,
bool  onOff 
)
private

Definition at line 250 of file FFTJetPFPileupCleaner.cc.

250  {
251  const unsigned shift = static_cast<unsigned>(ptype);
252  assert(shift < 32U);
253  const unsigned mask = (1U << shift);
254  if (value)
255  removalMask |= mask;
256  else
257  removalMask &= ~mask;
258 }

References cms::cuda::assert(), OfflineHarvestingSequence_cosmic::ptype, removalMask, edm::shift, and mitigatedMETSequence_cff::U.

Referenced by buildRemovalMask().

Member Data Documentation

◆ checkClosestZVertex

bool FFTJetPFPileupCleaner::checkClosestZVertex
private

Definition at line 85 of file FFTJetPFPileupCleaner.cc.

Referenced by findSomeVertexWFakes().

◆ etaMax

double FFTJetPFPileupCleaner::etaMax
private

Definition at line 121 of file FFTJetPFPileupCleaner.cc.

Referenced by produce().

◆ etaMin

double FFTJetPFPileupCleaner::etaMin
private

Definition at line 120 of file FFTJetPFPileupCleaner.cc.

◆ FakePrimaryVertices

edm::InputTag FFTJetPFPileupCleaner::FakePrimaryVertices
private

Definition at line 73 of file FFTJetPFPileupCleaner.cc.

Referenced by FFTJetPFPileupCleaner().

◆ FakePrimaryVerticesToken

edm::EDGetTokenT<reco::VertexCollection> FFTJetPFPileupCleaner::FakePrimaryVerticesToken
private

Definition at line 77 of file FFTJetPFPileupCleaner.cc.

Referenced by FFTJetPFPileupCleaner(), and produce().

◆ keepIfPVneighbor

bool FFTJetPFPileupCleaner::keepIfPVneighbor
private

Definition at line 92 of file FFTJetPFPileupCleaner.cc.

Referenced by findSomeVertexWFakes().

◆ PFCandidates

edm::InputTag FFTJetPFPileupCleaner::PFCandidates
private

Definition at line 71 of file FFTJetPFPileupCleaner.cc.

Referenced by FFTJetPFPileupCleaner().

◆ PFCandidatesToken

edm::EDGetTokenT<reco::PFCandidateCollection> FFTJetPFPileupCleaner::PFCandidatesToken
private

Definition at line 75 of file FFTJetPFPileupCleaner.cc.

Referenced by FFTJetPFPileupCleaner(), and produce().

◆ removalMask

unsigned FFTJetPFPileupCleaner::removalMask
private

Definition at line 117 of file FFTJetPFPileupCleaner.cc.

Referenced by isRemovable(), and setRemovalBit().

◆ remove_e

bool FFTJetPFPileupCleaner::remove_e
private

Definition at line 109 of file FFTJetPFPileupCleaner.cc.

Referenced by buildRemovalMask().

◆ remove_egamma_HF

bool FFTJetPFPileupCleaner::remove_egamma_HF
private

Definition at line 114 of file FFTJetPFPileupCleaner.cc.

Referenced by buildRemovalMask().

◆ remove_gamma

bool FFTJetPFPileupCleaner::remove_gamma
private

Definition at line 111 of file FFTJetPFPileupCleaner.cc.

Referenced by buildRemovalMask().

◆ remove_h

bool FFTJetPFPileupCleaner::remove_h
private

Definition at line 108 of file FFTJetPFPileupCleaner.cc.

Referenced by buildRemovalMask().

◆ remove_h0

bool FFTJetPFPileupCleaner::remove_h0
private

Definition at line 112 of file FFTJetPFPileupCleaner.cc.

Referenced by buildRemovalMask().

◆ remove_h_HF

bool FFTJetPFPileupCleaner::remove_h_HF
private

Definition at line 113 of file FFTJetPFPileupCleaner.cc.

Referenced by buildRemovalMask().

◆ remove_mu

bool FFTJetPFPileupCleaner::remove_mu
private

Definition at line 110 of file FFTJetPFPileupCleaner.cc.

Referenced by buildRemovalMask().

◆ remove_X

bool FFTJetPFPileupCleaner::remove_X
private

Definition at line 107 of file FFTJetPFPileupCleaner.cc.

Referenced by buildRemovalMask().

◆ removeMainVertex

bool FFTJetPFPileupCleaner::removeMainVertex
private

Definition at line 96 of file FFTJetPFPileupCleaner.cc.

Referenced by produce().

◆ removeUnassociated

bool FFTJetPFPileupCleaner::removeUnassociated
private

Definition at line 100 of file FFTJetPFPileupCleaner.cc.

Referenced by produce().

◆ reverseRemovalDecision

bool FFTJetPFPileupCleaner::reverseRemovalDecision
private

Definition at line 103 of file FFTJetPFPileupCleaner.cc.

Referenced by produce().

◆ useFakePrimaryVertex

bool FFTJetPFPileupCleaner::useFakePrimaryVertex
private

Definition at line 81 of file FFTJetPFPileupCleaner.cc.

Referenced by FFTJetPFPileupCleaner(), findSomeVertexWFakes(), and produce().

◆ vertexNdofCut

double FFTJetPFPileupCleaner::vertexNdofCut
private

Definition at line 124 of file FFTJetPFPileupCleaner.cc.

Referenced by isAcceptableVtx().

◆ vertexRhoCut

double FFTJetPFPileupCleaner::vertexRhoCut
private

Definition at line 130 of file FFTJetPFPileupCleaner.cc.

Referenced by isAcceptableVtx().

◆ vertexZmaxCut

double FFTJetPFPileupCleaner::vertexZmaxCut
private

Definition at line 127 of file FFTJetPFPileupCleaner.cc.

Referenced by isAcceptableVtx().

◆ Vertices

edm::InputTag FFTJetPFPileupCleaner::Vertices
private

Definition at line 72 of file FFTJetPFPileupCleaner.cc.

Referenced by FFTJetPFPileupCleaner().

◆ VerticesToken

edm::EDGetTokenT<reco::VertexCollection> FFTJetPFPileupCleaner::VerticesToken
private

Definition at line 76 of file FFTJetPFPileupCleaner.cc.

Referenced by FFTJetPFPileupCleaner(), and produce().

◆ zAssoc

std::vector<std::pair<double, unsigned> > FFTJetPFPileupCleaner::zAssoc
mutableprivate

Definition at line 133 of file FFTJetPFPileupCleaner.cc.

Referenced by findSomeVertexWFakes().

FFTJetPFPileupCleaner::reverseRemovalDecision
bool reverseRemovalDecision
Definition: FFTJetPFPileupCleaner.cc:103
reco::Vertex::trackRef_iterator
std::vector< TrackBaseRef >::const_iterator trackRef_iterator
The iteratator for the vector<TrackRef>
Definition: Vertex.h:38
FFTJetPFPileupCleaner::PFCandidates
edm::InputTag PFCandidates
Definition: FFTJetPFPileupCleaner.cc:71
pfDeepBoostedJetPreprocessParams_cfi.upper_bound
upper_bound
Definition: pfDeepBoostedJetPreprocessParams_cfi.py:16
zmumugammaAnalyzer_cfi.pfCandidates
pfCandidates
Definition: zmumugammaAnalyzer_cfi.py:11
mps_fire.i
i
Definition: mps_fire.py:428
FFTJetPFPileupCleaner::etaMax
double etaMax
Definition: FFTJetPFPileupCleaner.cc:121
reco::PFCandidate::e
Definition: PFCandidate.h:47
FFTJetPFPileupCleaner::zAssoc
std::vector< std::pair< double, unsigned > > zAssoc
Definition: FFTJetPFPileupCleaner.cc:133
FFTJetPFPileupCleaner::vertexNdofCut
double vertexNdofCut
Definition: FFTJetPFPileupCleaner.cc:124
FFTJetPFPileupCleaner::PFCandidatesToken
edm::EDGetTokenT< reco::PFCandidateCollection > PFCandidatesToken
Definition: FFTJetPFPileupCleaner.cc:75
FFTJetPFPileupCleaner::buildRemovalMask
void buildRemovalMask()
Definition: FFTJetPFPileupCleaner.cc:438
reco::PFCandidate::h
Definition: PFCandidate.h:46
FFTJetPFPileupCleaner::Vertices
edm::InputTag Vertices
Definition: FFTJetPFPileupCleaner.cc:72
OfflineHarvestingSequence_cosmic.ptype
ptype
Definition: OfflineHarvestingSequence_cosmic.py:7
reco::PFCandidate::h_HF
Definition: PFCandidate.h:51
cms::cuda::assert
assert(be >=bs)
FFTJetPFPileupCleaner::etaMin
double etaMin
Definition: FFTJetPFPileupCleaner.cc:120
FFTJetPFPileupCleaner::remove_h_HF
bool remove_h_HF
Definition: FFTJetPFPileupCleaner.cc:113
edm::Handle
Definition: AssociativeIterator.h:50
dqmdumpme.first
first
Definition: dqmdumpme.py:55
FFTJetPFPileupCleaner::VerticesToken
edm::EDGetTokenT< reco::VertexCollection > VerticesToken
Definition: FFTJetPFPileupCleaner.cc:76
edm::LogWarning
Log< level::Warning, false > LogWarning
Definition: MessageLogger.h:122
reco::PFCandidate::X
Definition: PFCandidate.h:45
edm::Ref< VertexCollection >
pfDeepBoostedJetPreprocessParams_cfi.pfcand
pfcand
Definition: pfDeepBoostedJetPreprocessParams_cfi.py:8
reco::PFCandidate::mu
Definition: PFCandidate.h:48
PVValHelper::eta
Definition: PVValidationHelpers.h:69
w
const double w
Definition: UKUtility.cc:23
init_param
#define init_param(type, varname)
Definition: FFTJetPFPileupCleaner.cc:40
FFTJetPFPileupCleaner::checkClosestZVertex
bool checkClosestZVertex
Definition: FFTJetPFPileupCleaner.cc:85
DDAxes::z
mitigatedMETSequence_cff.U
U
Definition: mitigatedMETSequence_cff.py:36
FFTJetPFPileupCleaner::remove_h0
bool remove_h0
Definition: FFTJetPFPileupCleaner.cc:112
FFTJetPFPileupCleaner::vertexZmaxCut
double vertexZmaxCut
Definition: FFTJetPFPileupCleaner.cc:127
FFTJetPFPileupCleaner::vertexRhoCut
double vertexRhoCut
Definition: FFTJetPFPileupCleaner.cc:130
FFTJetPFPileupCleaner::remove_gamma
bool remove_gamma
Definition: FFTJetPFPileupCleaner.cc:111
FFTJetPFPileupCleaner::isAcceptableVtx
bool isAcceptableVtx(reco::VertexCollection::const_iterator iv) const
Definition: FFTJetPFPileupCleaner.cc:175
reco::PFCandidate::egamma_HF
Definition: PFCandidate.h:52
reco::VertexRef
edm::Ref< VertexCollection > VertexRef
persistent reference to a Vertex
Definition: VertexFwd.h:13
cand
Definition: decayParser.h:32
iEvent
int iEvent
Definition: GenABIO.cc:224
FFTJetPFPileupCleaner::removeUnassociated
bool removeUnassociated
Definition: FFTJetPFPileupCleaner.cc:100
value
Definition: value.py:1
reco::PFCandidate::gamma
Definition: PFCandidate.h:49
FFTJetPFPileupCleaner::remove_X
bool remove_X
Definition: FFTJetPFPileupCleaner.cc:107
FFTJetPFPileupCleaner::useFakePrimaryVertex
bool useFakePrimaryVertex
Definition: FFTJetPFPileupCleaner.cc:81
IT
std::vector< LinkConnSpec >::const_iterator IT
Definition: TriggerBoardSpec.cc:5
edm::Ptr< PFCandidate >
FFTJetPFPileupCleaner::FakePrimaryVerticesToken
edm::EDGetTokenT< reco::VertexCollection > FakePrimaryVerticesToken
Definition: FFTJetPFPileupCleaner.cc:77
eostools.move
def move(src, dest)
Definition: eostools.py:511
edm::shift
static unsigned const int shift
Definition: LuminosityBlockID.cc:7
extraflags_cff.vtx
vtx
Definition: extraflags_cff.py:18
PVValHelper::dz
Definition: PVValidationHelpers.h:50
reco::PFCandidate::h0
Definition: PFCandidate.h:50
FFTJetPFPileupCleaner::FakePrimaryVertices
edm::InputTag FakePrimaryVertices
Definition: FFTJetPFPileupCleaner.cc:73
FFTJetPFPileupCleaner::setRemovalBit
void setRemovalBit(reco::PFCandidate::ParticleType ptype, bool onOff)
Definition: FFTJetPFPileupCleaner.cc:250
MatrixUtil.remove
def remove(d, key, TELL=False)
Definition: MatrixUtil.py:219
FFTJetPFPileupCleaner::findSomeVertexWFakes
reco::VertexRef findSomeVertexWFakes(const edm::Handle< reco::VertexCollection > &vertices, const edm::Handle< reco::VertexCollection > &fakeVertices, const reco::PFCandidate &pfcand, bool *fromFakeSet) const
Definition: FFTJetPFPileupCleaner.cc:263
edm::RefToBase< reco::Track >
FFTJetPFPileupCleaner::remove_h
bool remove_h
Definition: FFTJetPFPileupCleaner.cc:108
FFTJetPFPileupCleaner::remove_e
bool remove_e
Definition: FFTJetPFPileupCleaner.cc:109
AlignmentPI::index
index
Definition: AlignmentPayloadInspectorHelper.h:46
reco::PFCandidate
Particle reconstructed by the particle flow algorithm.
Definition: PFCandidate.h:41
FFTJetPFPileupCleaner::removalMask
unsigned removalMask
Definition: FFTJetPFPileupCleaner.cc:117
FFTJetPFPileupCleaner::remove_egamma_HF
bool remove_egamma_HF
Definition: FFTJetPFPileupCleaner.cc:114
cms::Exception
Definition: Exception.h:70
funct::abs
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
FFTJetPFPileupCleaner::remove_mu
bool remove_mu
Definition: FFTJetPFPileupCleaner.cc:110
edm::HandleBase::isValid
bool isValid() const
Definition: HandleBase.h:70
FFTJetPFPileupCleaner::keepIfPVneighbor
bool keepIfPVneighbor
Definition: FFTJetPFPileupCleaner.cc:92
edm::InputTag
Definition: InputTag.h:15
reco::Vertex
Definition: Vertex.h:35
FFTJetPFPileupCleaner::removeMainVertex
bool removeMainVertex
Definition: FFTJetPFPileupCleaner.cc:96
pwdgSkimBPark_cfi.vertices
vertices
Definition: pwdgSkimBPark_cfi.py:7
FFTJetPFPileupCleaner::isRemovable
bool isRemovable(reco::PFCandidate::ParticleType ptype) const
Definition: FFTJetPFPileupCleaner.cc:244