CMS 3D CMS Logo

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

#include <L1RCTRelValAnalyzer.h>

Inheritance diagram for L1RCTRelValAnalyzer:
edm::EDAnalyzer edm::EDConsumerBase

Public Member Functions

void analyze (const edm::Event &, const edm::EventSetup &) override
 
 L1RCTRelValAnalyzer (const edm::ParameterSet &)
 
 ~L1RCTRelValAnalyzer () override
 
- Public Member Functions inherited from edm::EDAnalyzer
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzer ()
 
SerialTaskQueueglobalLuminosityBlocksQueue ()
 
SerialTaskQueueglobalRunsQueue ()
 
ModuleDescription const & moduleDescription () const
 
std::string workerType () const
 
 ~EDAnalyzer () 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 const &)=delete
 
 EDConsumerBase (EDConsumerBase &&)=default
 
ESProxyIndex const * esGetTokenIndices (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
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
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)
 

Private Attributes

TH1F * h_emIeta
 
TH1F * h_emIphi
 
TH2F * h_emIsoOccIetaIphi
 
TH2F * h_emNonIsoOccIetaIphi
 
TH1F * h_emRank
 
TH2F * h_regionOccIetaIphi
 
TH1F * h_regionSum
 
TH2F * h_regionSumIetaIphi
 
edm::InputTag rctEmCandsLabel
 
edm::InputTag rctRegionsLabel
 

Additional Inherited Members

- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::EDAnalyzer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &)
 
static bool wantsGlobalLuminosityBlocks ()
 
static bool wantsGlobalRuns ()
 
static bool wantsStreamLuminosityBlocks ()
 
static bool wantsStreamRuns ()
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
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<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 

Detailed Description

L1Trigger/RegionalCaloTrigger/interface/L1RCTRelValAnalyzer.h L1Trigger/RegionalCaloTrigger/plugins/L1RCTRelValAnalyzer.cc

Description: <one line="" class="" summary>="">

Implementation: <Notes on="" implementation>="">

Definition at line 45 of file L1RCTRelValAnalyzer.h.

Constructor & Destructor Documentation

L1RCTRelValAnalyzer::L1RCTRelValAnalyzer ( const edm::ParameterSet iConfig)
explicit

Definition at line 25 of file L1RCTRelValAnalyzer.cc.

References h_emIeta, h_emIphi, h_emIsoOccIetaIphi, h_emNonIsoOccIetaIphi, h_emRank, h_regionOccIetaIphi, h_regionSum, h_regionSumIetaIphi, and TFileService::make().

26  : rctEmCandsLabel(iConfig.getParameter<edm::InputTag>("rctEmCandsLabel")),
27  rctRegionsLabel(iConfig.getParameter<edm::InputTag>("rctRegionsLabel")) {
28  // now do what ever initialization is needed
29 
31  h_emRank = fs->make<TH1F>("emRank", "emRank", 64, 0., 64.);
32  h_emIeta = fs->make<TH1F>("emOccupancyIeta", "emOccupancyIeta", 22, 0., 22.);
33  h_emIphi = fs->make<TH1F>("emOccupancyIphi", "emOccupancyIphi", 18, 0., 18.);
34  h_emIsoOccIetaIphi = fs->make<TH2F>("emIsoOccupancy2D", "emIsoOccupancy2D",
35  22, 0., 22., 18, 0., 18.);
36  h_emNonIsoOccIetaIphi = fs->make<TH2F>(
37  "emNonIsoOccupancy2D", "emNonIsoOccupancy2D", 22, 0., 22., 18, 0., 18.);
38 
39  h_regionSum = fs->make<TH1F>("regionSum", "regionSum", 100, 0., 100.);
41  fs->make<TH2F>("regionSumEtWeighted2D", "regionSumEtWeighted2D", 22, 0.,
42  22., 18, 0., 18.);
43  h_regionOccIetaIphi = fs->make<TH2F>("regionOccupancy2D", "regionOccupancy2D",
44  22, 0., 22., 18, 0., 18.);
45 }
T getParameter(std::string const &) const
T * make(const Args &...args) const
make new ROOT object
Definition: TFileService.h:64
edm::InputTag rctEmCandsLabel
edm::InputTag rctRegionsLabel
L1RCTRelValAnalyzer::~L1RCTRelValAnalyzer ( )
override

Definition at line 47 of file L1RCTRelValAnalyzer.cc.

47  {
48 
49  // do anything here that needs to be done at destruction time
50  // (e.g. close files, deallocate resources etc.)
51 }

Member Function Documentation

void L1RCTRelValAnalyzer::analyze ( const edm::Event iEvent,
const edm::EventSetup iSetup 
)
override

Definition at line 58 of file L1RCTRelValAnalyzer.cc.

References edm::EventSetup::get(), edm::Event::getByLabel(), h_emIeta, h_emIphi, h_emIsoOccIetaIphi, h_emNonIsoOccIetaIphi, h_emRank, h_regionOccIetaIphi, h_regionSum, h_regionSumIetaIphi, rctEmCandsLabel, and rctRegionsLabel.

59  {
60  using namespace edm;
61 #ifdef THIS_IS_AN_EVENT_EXAMPLE
63  iEvent.getByLabel("example", pIn);
64 #endif
65 
66 #ifdef THIS_IS_AN_EVENTSETUP_EXAMPLE
67  ESHandle<SetupData> pSetup;
68  iSetup.get<SetupRecord>().get(pSetup);
69 #endif
70 
71  // as in L1GctTestAnalyzer.cc
72  Handle<L1CaloEmCollection> rctEmCands;
74 
75  L1CaloEmCollection::const_iterator em;
76  L1CaloRegionCollection::const_iterator rgn;
77 
78  iEvent.getByLabel(rctEmCandsLabel, rctEmCands);
79  iEvent.getByLabel(rctRegionsLabel, rctRegions);
80 
81  for (em = rctEmCands->begin(); em != rctEmCands->end(); em++) {
82  if ((*em).rank() > 0) {
83  h_emRank->Fill((*em).rank());
84  h_emIeta->Fill((*em).regionId().ieta());
85  h_emIphi->Fill((*em).regionId().iphi());
86  if ((*em).isolated()) {
87  h_emIsoOccIetaIphi->Fill((*em).regionId().ieta(),
88  (*em).regionId().iphi());
89  } else {
90  h_emNonIsoOccIetaIphi->Fill((*em).regionId().ieta(),
91  (*em).regionId().iphi());
92  }
93  }
94  }
95 
96  for (rgn = rctRegions->begin(); rgn != rctRegions->end(); rgn++) {
97  if ((*rgn).et() > 0) {
98  h_regionSum->Fill((*rgn).et());
99  h_regionSumIetaIphi->Fill((*rgn).gctEta(), (*rgn).gctPhi(), (*rgn).et());
100  h_regionOccIetaIphi->Fill((*rgn).gctEta(), (*rgn).gctPhi());
101  }
102  }
103 }
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
Definition: Event.h:480
edm::InputTag rctEmCandsLabel
edm::InputTag rctRegionsLabel
HLT enums.
T get() const
Definition: EventSetup.h:71

Member Data Documentation

TH1F* L1RCTRelValAnalyzer::h_emIeta
private

Definition at line 58 of file L1RCTRelValAnalyzer.h.

Referenced by analyze(), and L1RCTRelValAnalyzer().

TH1F* L1RCTRelValAnalyzer::h_emIphi
private

Definition at line 59 of file L1RCTRelValAnalyzer.h.

Referenced by analyze(), and L1RCTRelValAnalyzer().

TH2F* L1RCTRelValAnalyzer::h_emIsoOccIetaIphi
private

Definition at line 60 of file L1RCTRelValAnalyzer.h.

Referenced by analyze(), and L1RCTRelValAnalyzer().

TH2F* L1RCTRelValAnalyzer::h_emNonIsoOccIetaIphi
private

Definition at line 61 of file L1RCTRelValAnalyzer.h.

Referenced by analyze(), and L1RCTRelValAnalyzer().

TH1F* L1RCTRelValAnalyzer::h_emRank
private

Definition at line 57 of file L1RCTRelValAnalyzer.h.

Referenced by analyze(), and L1RCTRelValAnalyzer().

TH2F* L1RCTRelValAnalyzer::h_regionOccIetaIphi
private

Definition at line 65 of file L1RCTRelValAnalyzer.h.

Referenced by analyze(), and L1RCTRelValAnalyzer().

TH1F* L1RCTRelValAnalyzer::h_regionSum
private

Definition at line 63 of file L1RCTRelValAnalyzer.h.

Referenced by analyze(), and L1RCTRelValAnalyzer().

TH2F* L1RCTRelValAnalyzer::h_regionSumIetaIphi
private

Definition at line 64 of file L1RCTRelValAnalyzer.h.

Referenced by analyze(), and L1RCTRelValAnalyzer().

edm::InputTag L1RCTRelValAnalyzer::rctEmCandsLabel
private

Definition at line 54 of file L1RCTRelValAnalyzer.h.

Referenced by analyze().

edm::InputTag L1RCTRelValAnalyzer::rctRegionsLabel
private

Definition at line 55 of file L1RCTRelValAnalyzer.h.

Referenced by analyze().