CMS 3D CMS Logo

List of all members | Public Member Functions
NanoAODSimpleCrossCleaner Class Reference
Inheritance diagram for NanoAODSimpleCrossCleaner:
NanoAODBaseCrossCleaner edm::stream::EDProducer<>

Public Member Functions

 NanoAODSimpleCrossCleaner (const edm::ParameterSet &p)
 
void objectSelection (const edm::View< pat::Jet > &jets, const edm::View< pat::Muon > &muons, const edm::View< pat::Electron > &eles, const edm::View< pat::Tau > &taus, const edm::View< pat::Photon > &photons, std::vector< uint8_t > &jetBits, std::vector< uint8_t > &muonBits, std::vector< uint8_t > &eleBits, std::vector< uint8_t > &tauBits, std::vector< uint8_t > &photonBits) override
 
 ~NanoAODSimpleCrossCleaner () override
 
- Public Member Functions inherited from NanoAODBaseCrossCleaner
 NanoAODBaseCrossCleaner (const edm::ParameterSet &)
 
 ~NanoAODBaseCrossCleaner () override
 
- Public Member Functions inherited from edm::stream::EDProducer<>
 EDProducer ()=default
 
bool hasAbilityToProduceInBeginLumis () const final
 
bool hasAbilityToProduceInBeginRuns () const final
 
bool hasAbilityToProduceInEndLumis () const final
 
bool hasAbilityToProduceInEndRuns () const final
 

Additional Inherited Members

- Public Types inherited from edm::stream::EDProducer<>
typedef CacheContexts< T... > CacheTypes
 
typedef CacheTypes::GlobalCache GlobalCache
 
typedef AbilityChecker< T... > HasAbility
 
typedef CacheTypes::LuminosityBlockCache LuminosityBlockCache
 
typedef LuminosityBlockContextT< LuminosityBlockCache, RunCache, GlobalCacheLuminosityBlockContext
 
typedef CacheTypes::LuminosityBlockSummaryCache LuminosityBlockSummaryCache
 
typedef CacheTypes::RunCache RunCache
 
typedef RunContextT< RunCache, GlobalCacheRunContext
 
typedef CacheTypes::RunSummaryCache RunSummaryCache
 
- Static Public Member Functions inherited from NanoAODBaseCrossCleaner
static void fillDescriptions (edm::ConfigurationDescriptions &descriptions)
 

Detailed Description

Definition at line 3 of file NanoAODSimpleCrossCleaner.cc.

Constructor & Destructor Documentation

◆ NanoAODSimpleCrossCleaner()

NanoAODSimpleCrossCleaner::NanoAODSimpleCrossCleaner ( const edm::ParameterSet p)
inline

Definition at line 5 of file NanoAODSimpleCrossCleaner.cc.

◆ ~NanoAODSimpleCrossCleaner()

NanoAODSimpleCrossCleaner::~NanoAODSimpleCrossCleaner ( )
inlineoverride

Definition at line 6 of file NanoAODSimpleCrossCleaner.cc.

6 {}

Member Function Documentation

◆ objectSelection()

void NanoAODSimpleCrossCleaner::objectSelection ( const edm::View< pat::Jet > &  jets,
const edm::View< pat::Muon > &  muons,
const edm::View< pat::Electron > &  eles,
const edm::View< pat::Tau > &  taus,
const edm::View< pat::Photon > &  photons,
std::vector< uint8_t > &  jetBits,
std::vector< uint8_t > &  muonBits,
std::vector< uint8_t > &  eleBits,
std::vector< uint8_t > &  tauBits,
std::vector< uint8_t > &  photonBits 
)
inlineoverridevirtual

Reimplemented from NanoAODBaseCrossCleaner.

Definition at line 8 of file NanoAODSimpleCrossCleaner.cc.

17  {
18  for (size_t i = 0; i < jets.size(); i++) {
19  for (const auto& m : jets[i].overlaps("muons")) {
20  if (muonBits[m.key()])
21  jetBits[i] = 0; //prefer muons
22  }
23  for (const auto& m : jets[i].overlaps("electrons")) {
24  if (eleBits[m.key()])
25  jetBits[i] = 0; //prefer electrons
26  }
27  }
28  }

References mps_fire::i, singleTopDQM_cfi::jets, visualization-live-secondInstance_cfg::m, and analyzePatCleaning_cfg::overlaps.

mps_fire.i
i
Definition: mps_fire.py:355
AlCaHLTBitMon_ParallelJobs.p
p
Definition: AlCaHLTBitMon_ParallelJobs.py:153
NanoAODBaseCrossCleaner::NanoAODBaseCrossCleaner
NanoAODBaseCrossCleaner(const edm::ParameterSet &)
Definition: NanoAODBaseCrossCleaner.cc:25
singleTopDQM_cfi.jets
jets
Definition: singleTopDQM_cfi.py:42
visualization-live-secondInstance_cfg.m
m
Definition: visualization-live-secondInstance_cfg.py:72
analyzePatCleaning_cfg.overlaps
overlaps
Definition: analyzePatCleaning_cfg.py:9