37 emTree =
fs->make<TTree>(
"emTree",
"L1 RCT EM tree");
47 h_emRank =
fs->make<TH1F>(
"emRank",
"emRank", 64, 0., 64.);
49 h_emIeta =
fs->make<TH1F>(
"emIeta",
"emIeta", 22, 0., 22.);
50 h_emIphi =
fs->make<TH1F>(
"emIphi",
"emIphi", 18, 0., 18.);
51 h_emIso =
fs->make<TH1F>(
"emIso",
"emIso", 2, 0., 2.);
57 h_regionSum =
fs->make<TH1F>(
"regionSum",
"regionSum", 100, 0., 100.);
58 h_regionIeta =
fs->make<TH1F>(
"regionIeta",
"regionIeta", 22, 0., 22.);
59 h_regionIphi =
fs->make<TH1F>(
"regionIphi",
"regionIphi", 18, 0., 18.);
60 h_regionMip =
fs->make<TH1F>(
"regionMip",
"regionMipBit", 2, 0., 2.);
64 h_towerMip =
fs->make<TH1F>(
"towerMip",
"towerMipBit", 2, 0., 2.);
84 #ifdef THIS_IS_AN_EVENT_EXAMPLE 86 iEvent.getByLabel(
"example", pIn);
89 #ifdef THIS_IS_AN_EVENTSETUP_EXAMPLE 91 iSetup.
get<SetupRecord>().
get(pSetup);
100 L1CaloEmCollection::const_iterator em;
101 L1CaloRegionCollection::const_iterator rgn;
129 for (em = rctEmCands->begin(); em != rctEmCands->end(); em++) {
133 (*myL1EmColl).push_back(*myL1EmCand);
137 if ((*em).bx() == 0) {
140 if ((*em).rank() > 0) {
142 h_emIeta->Fill((*em).regionId().ieta());
143 h_emIphi->Fill((*em).regionId().iphi());
144 h_emIso->Fill((*em).isolated());
145 h_emRankInIetaIphi->Fill((*em).regionId().ieta(), (*em).regionId().iphi(), (*em).rank());
146 if ((*em).isolated()) {
154 if ((*em).rank() > 0) {
156 unsigned short rgnPhi = 999;
157 unsigned short rgn = (
unsigned short)(*em).rctRegion();
158 unsigned short card = (
unsigned short)(*em).rctCard();
159 unsigned short crate = (
unsigned short)(*em).rctCrate();
163 }
else if (card < 6) {
166 std::cout <<
"rgnPhi not assigned (still " << rgnPhi <<
") -- Weird card number! " << card;
170 short eta_bin = (card / 2) * 2 + 1;
172 eta_bin = eta_bin + rgn;
197 for (em = myL1EmColl->begin(); em != myL1EmColl->end(); em++) {
198 emRank.push_back((*em).rank());
199 emIeta.push_back((*em).regionId().ieta());
200 emIphi.push_back((*em).regionId().iphi());
201 emIso.push_back((*em).isolated());
208 for (rgn = rctRegions->begin(); rgn != rctRegions->end(); rgn++) {
209 if ((*rgn).bx() == 0) {
213 if ((*rgn).et() > 0) {
236 return (cand1.
rank() < cand2.
rank());
static const std::string kSharedResource
void analyze(const edm::Event &, const edm::EventSetup &) override
std::vector< int > emIeta
std::vector< L1CaloEmCand > L1CaloEmCollection
TH2F * h_regionSumInIetaIphi
static bool compareEmCands(const L1CaloEmCand &cand1, const L1CaloEmCand &cand2)
std::vector< T >::const_iterator const_iterator
Level-1 Region Calorimeter Trigger EM candidate.
TH2F * h_emRankInIetaIphi
TH1F * h_emCandTimeSample
TH2F * h_emNonIsoInIetaIphi
~L1RCTTestAnalyzer() override
std::vector< int > emRank
edm::InputTag rctDigisLabel
const_iterator begin() const
L1RCTTestAnalyzer(const edm::ParameterSet &)
edm::InputTag hcalDigisLabel
const_iterator end() const
unsigned rank() const
get rank bits
TH2F * h_regionFGInIetaIphi
edm::InputTag ecalDigisLabel
std::vector< int > emIphi