00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089
00090
00091
00092
00093
00094
00095
00096
00097
00098
00099
00100
00101
00102
00103
00104
00105
00106
00107
00108
00109
00110
00111
00112
00113
00114
00115
00116
00117
00118
00119
00120
00121
00122
00123
00124
00125
00126
00127
00128
00129
00130
00131
00132
00133
00134
00135
00136
00137
00138
00139
00140
00141
00142
00143
00144
00145
00146
00147
00148
00149
00150
00151
00152
00153
00154
00155
00156
00157
00158
00159
00160
00161
00162
00163
00164
00165
00166
00167
00168
00169
00170
00171
00172
00173
00174
00175
00176
00177
00178
00179
00180
00181
00182
00183 #include "DQM/L1TMonitor/interface/L1TGCT.h"
00184 #include "FWCore/MessageLogger/interface/MessageLogger.h"
00185 #include "DataFormats/Provenance/interface/EventAuxiliary.h"
00186
00187
00188
00189
00190 #include "DataFormats/L1GlobalCaloTrigger/interface/L1GctCollections.h"
00191 #include "DataFormats/L1GlobalCaloTrigger/interface/L1GctEtSums.h"
00192 #include "DQMServices/Core/interface/DQMStore.h"
00193
00194 using namespace edm;
00195
00196
00197 const unsigned int JETETABINS = 22;
00198 const float JETETAMIN = -0.5;
00199 const float JETETAMAX = 21.5;
00200
00201 const unsigned int EMETABINS = 22;
00202 const float EMETAMIN = -0.5;
00203 const float EMETAMAX = 21.5;
00204
00205 const unsigned int METPHIBINS = 72;
00206 const float METPHIMIN = -0.5;
00207 const float METPHIMAX = 71.5;
00208
00209 const unsigned int MHTPHIBINS = 18;
00210 const float MHTPHIMIN = -0.5;
00211 const float MHTPHIMAX = 17.5;
00212
00213 const unsigned int PHIBINS = 18;
00214 const float PHIMIN = -0.5;
00215 const float PHIMAX = 17.5;
00216
00217 const unsigned int OFBINS = 2;
00218 const float OFMIN = -0.5;
00219 const float OFMAX = 1.5;
00220
00221 const unsigned int BXBINS = 5;
00222 const float BXMIN = -2.5;
00223 const float BXMAX = 2.5;
00224
00225
00226 const unsigned int R3BINS = 8;
00227 const float R3MIN = -0.5;
00228 const float R3MAX = 7.5;
00229 const unsigned int R5BINS = 32;
00230 const float R5MIN = -0.5;
00231 const float R5MAX = 31.5;
00232 const unsigned int R6BINS = 64;
00233 const float R6MIN = -0.5;
00234 const float R6MAX = 63.5;
00235 const unsigned int R7BINS = 128;
00236 const float R7MIN = -0.5;
00237 const float R7MAX = 127.5;
00238 const unsigned int R10BINS = 1024;
00239 const float R10MIN = -0.5;
00240 const float R10MAX = 1023.5;
00241 const unsigned int R12BINS = 4096;
00242 const float R12MIN = -0.5;
00243 const float R12MAX = 4095.5;
00244
00245 L1TGCT::L1TGCT(const edm::ParameterSet & ps) :
00246 gctCenJetsSource_(ps.getParameter<edm::InputTag>("gctCentralJetsSource")),
00247 gctForJetsSource_(ps.getParameter<edm::InputTag>("gctForwardJetsSource")),
00248 gctTauJetsSource_(ps.getParameter<edm::InputTag>("gctTauJetsSource")),
00249 gctEnergySumsSource_(ps.getParameter<edm::InputTag>("gctEnergySumsSource")),
00250 gctIsoEmSource_(ps.getParameter<edm::InputTag>("gctIsoEmSource")),
00251 gctNonIsoEmSource_(ps.getParameter<edm::InputTag>("gctNonIsoEmSource")),
00252 filterTriggerType_ (ps.getParameter< int >("filterTriggerType"))
00253 {
00254
00255
00256 verbose_ = ps.getUntrackedParameter < bool > ("verbose", false);
00257
00258 if (verbose_)
00259 edm::LogInfo("L1TGCT") << "L1TGCT: constructor...." << std::endl;
00260
00261
00262 dbe = NULL;
00263 if (ps.getUntrackedParameter < bool > ("DQMStore", false)) {
00264 dbe = edm::Service < DQMStore > ().operator->();
00265 dbe->setVerbose(0);
00266 }
00267
00268 outputFile_ = ps.getUntrackedParameter < std::string > ("outputFile", "");
00269 if (outputFile_.size() != 0) {
00270 edm::LogInfo("L1TGCT") << "L1T Monitoring histograms will be saved to "
00271 << outputFile_ << std::endl;
00272 }
00273
00274 bool disable = ps.getUntrackedParameter<bool>("disableROOToutput", false);
00275 if(disable){
00276 outputFile_="";
00277 }
00278
00279
00280 if (dbe != NULL) {
00281 dbe->setCurrentFolder("L1T/L1TGCT");
00282 }
00283
00284 }
00285
00286 L1TGCT::~L1TGCT()
00287 {
00288 }
00289
00290 void L1TGCT::beginJob(void)
00291 {
00292
00293 nev_ = 0;
00294
00295
00296 DQMStore *dbe = 0;
00297 dbe = edm::Service < DQMStore > ().operator->();
00298
00299 if (dbe) {
00300 dbe->setCurrentFolder("L1T/L1TGCT");
00301 dbe->rmdir("L1T/L1TGCT");
00302 }
00303
00304
00305 if (dbe) {
00306
00307 dbe->setCurrentFolder("L1T/L1TGCT");
00308
00309 triggerType_ =
00310 dbe->book1D("TriggerType", "TriggerType", 17, -0.5, 16.5);
00311
00312 l1GctAllJetsEtEtaPhi_ = dbe->book2D("AllJetsEtEtaPhi", "CENTRAL AND FORWARD JET E_{T}",
00313 JETETABINS, JETETAMIN, JETETAMAX,
00314 PHIBINS, PHIMIN, PHIMAX);
00315 l1GctCenJetsEtEtaPhi_ = dbe->book2D("CenJetsEtEtaPhi", "CENTRAL JET E_{T}",
00316 JETETABINS, JETETAMIN, JETETAMAX,
00317 PHIBINS, PHIMIN, PHIMAX);
00318 l1GctForJetsEtEtaPhi_ = dbe->book2D("ForJetsEtEtaPhi", "FORWARD JET E_{T}",
00319 JETETABINS, JETETAMIN, JETETAMAX,
00320 PHIBINS, PHIMIN, PHIMAX);
00321 l1GctTauJetsEtEtaPhi_ = dbe->book2D("TauJetsEtEtaPhi", "TAU JET E_{T}",
00322 EMETABINS, EMETAMIN, EMETAMAX,
00323 PHIBINS, PHIMIN, PHIMAX);
00324 l1GctIsoEmRankEtaPhi_ = dbe->book2D("IsoEmRankEtaPhi", "ISO EM E_{T}",
00325 EMETABINS, EMETAMIN, EMETAMAX,
00326 PHIBINS, PHIMIN, PHIMAX);
00327 l1GctNonIsoEmRankEtaPhi_ = dbe->book2D("NonIsoEmRankEtaPhi", "NON-ISO EM E_{T}",
00328 EMETABINS, EMETAMIN, EMETAMAX,
00329 PHIBINS, PHIMIN, PHIMAX);
00330 l1GctAllJetsOccEtaPhi_ = dbe->book2D("AllJetsOccEtaPhi", "CENTRAL AND FORWARD JET OCCUPANCY",
00331 JETETABINS, JETETAMIN, JETETAMAX,
00332 PHIBINS, PHIMIN, PHIMAX);
00333 l1GctCenJetsOccEtaPhi_ = dbe->book2D("CenJetsOccEtaPhi", "CENTRAL JET OCCUPANCY",
00334 JETETABINS, JETETAMIN, JETETAMAX,
00335 PHIBINS, PHIMIN, PHIMAX);
00336 l1GctForJetsOccEtaPhi_ = dbe->book2D("ForJetsOccEtaPhi", "FORWARD JET OCCUPANCY",
00337 JETETABINS, JETETAMIN, JETETAMAX,
00338 PHIBINS, PHIMIN, PHIMAX);
00339 l1GctTauJetsOccEtaPhi_ = dbe->book2D("TauJetsOccEtaPhi", "TAU JET OCCUPANCY",
00340 EMETABINS, EMETAMIN, EMETAMAX,
00341 PHIBINS, PHIMIN, PHIMAX);
00342 l1GctIsoEmOccEtaPhi_ = dbe->book2D("IsoEmOccEtaPhi", "ISO EM OCCUPANCY",
00343 EMETABINS, EMETAMIN, EMETAMAX,
00344 PHIBINS, PHIMIN, PHIMAX);
00345 l1GctNonIsoEmOccEtaPhi_ = dbe->book2D("NonIsoEmOccEtaPhi", "NON-ISO EM OCCUPANCY",
00346 EMETABINS, EMETAMIN, EMETAMAX,
00347 PHIBINS, PHIMIN, PHIMAX);
00348
00349 l1GctHFRing1PosEtaNegEta_ = dbe->book2D("HFRing1Corr", "HF RING1 E_{T} CORRELATION +/- #eta",
00350 R3BINS, R3MIN, R3MAX, R3BINS, R3MIN, R3MAX);
00351 l1GctHFRing2PosEtaNegEta_ = dbe->book2D("HFRing2Corr", "HF RING2 E_{T} CORRELATION +/- #eta",
00352 R3BINS, R3MIN, R3MAX, R3BINS, R3MIN, R3MAX);
00353 l1GctHFRing1TowerCountPosEtaNegEta_ = dbe->book2D("HFRing1TowerCountCorr", "HF RING1 TOWER COUNT CORRELATION +/- #eta",
00354 R3BINS, R3MIN, R3MAX, R3BINS, R3MIN, R3MAX);
00355 l1GctHFRing2TowerCountPosEtaNegEta_ = dbe->book2D("HFRing2TowerCountCorr", "HF RING2 TOWER COUNT CORRELATION +/- #eta",
00356 R3BINS, R3MIN, R3MAX, R3BINS, R3MIN, R3MAX);
00357
00358
00359 l1GctHFRing1TowerCountPosEta_ = dbe->book1D("HFRing1TowerCountPosEta", "HF RING1 TOWER COUNT #eta +", R3BINS, R3MIN, R3MAX);
00360 l1GctHFRing1TowerCountNegEta_ = dbe->book1D("HFRing1TowerCountNegEta", "HF RING1 TOWER COUNT #eta -", R3BINS, R3MIN, R3MAX);
00361 l1GctHFRing2TowerCountPosEta_ = dbe->book1D("HFRing2TowerCountPosEta", "HF RING2 TOWER COUNT #eta +", R3BINS, R3MIN, R3MAX);
00362 l1GctHFRing2TowerCountNegEta_ = dbe->book1D("HFRing2TowerCountNegEta", "HF RING2 TOWER COUNT #eta -", R3BINS, R3MIN, R3MAX);
00363
00364 l1GctHFRing1ETSumPosEta_ = dbe->book1D("HFRing1ETSumPosEta", "HF RING1 E_{T} #eta +", R3BINS, R3MIN, R3MAX);
00365 l1GctHFRing1ETSumNegEta_ = dbe->book1D("HFRing1ETSumNegEta", "HF RING1 E_{T} #eta -", R3BINS, R3MIN, R3MAX);
00366 l1GctHFRing2ETSumPosEta_ = dbe->book1D("HFRing2ETSumPosEta", "HF RING2 E_{T} #eta +", R3BINS, R3MIN, R3MAX);
00367 l1GctHFRing2ETSumNegEta_ = dbe->book1D("HFRing2ETSumNegEta", "HF RING2 E_{T} #eta -", R3BINS, R3MIN, R3MAX);
00368 l1GctHFRingRatioPosEta_ = dbe->book1D("HFRingRatioPosEta", "HF RING E_{T} RATIO #eta +", R5BINS, R5MIN, R5MAX);
00369 l1GctHFRingRatioNegEta_ = dbe->book1D("HFRingRatioNegEta", "HF RING E_{T} RATIO #eta -", R5BINS, R5MIN, R5MAX);
00370
00371 l1GctHFRingTowerCountOccBx_ = dbe->book2D("HFRingTowerCountOccBx", "HF RING TOWER COUNT PER BX",BXBINS, BXMIN, BXMAX, R3BINS, R3MIN, R3MAX);
00372 l1GctHFRingETSumOccBx_ = dbe->book2D("HFRingETSumOccBx", "HF RING E_{T} PER BX",BXBINS, BXMIN, BXMAX, R3BINS, R3MIN, R3MAX);
00373
00374
00375 l1GctCenJetsRank_ = dbe->book1D("CenJetsRank", "CENTRAL JET E_{T}", R6BINS, R6MIN, R6MAX);
00376 l1GctForJetsRank_ = dbe->book1D("ForJetsRank", "FORWARD JET E_{T}", R6BINS, R6MIN, R6MAX);
00377 l1GctTauJetsRank_ = dbe->book1D("TauJetsRank", "TAU JET E_{T}", R6BINS, R6MIN, R6MAX);
00378 l1GctIsoEmRank_ = dbe->book1D("IsoEmRank", "ISO EM E_{T}", R6BINS, R6MIN, R6MAX);
00379 l1GctNonIsoEmRank_ = dbe->book1D("NonIsoEmRank", "NON-ISO EM E_{T}", R6BINS, R6MIN, R6MAX);
00380
00381 l1GctAllJetsOccRankBx_ = dbe->book2D("AllJetsOccRankBx","ALL JETS E_{T} PER BX",BXBINS,BXMIN,BXMAX,R6BINS,R6MIN,R6MAX);
00382 l1GctAllEmOccRankBx_ = dbe->book2D("AllEmOccRankBx","ALL EM E_{T} PER BX",BXBINS,BXMIN,BXMAX,R6BINS,R6MIN,R6MAX);
00383
00384
00385 l1GctEtMiss_ = dbe->book1D("EtMiss", "MET", R12BINS, R12MIN, R12MAX);
00386 l1GctEtMissPhi_ = dbe->book1D("EtMissPhi", "MET #phi", METPHIBINS, METPHIMIN, METPHIMAX);
00387 l1GctEtMissOf_ = dbe->book1D("EtMissOf", "MET OVERFLOW", OFBINS, OFMIN, OFMAX);
00388 l1GctEtMissOccBx_ = dbe->book2D("EtMissOccBx","MET PER BX",BXBINS,BXMIN,BXMAX,R12BINS,R12MIN,R12MAX);
00389 l1GctHtMiss_ = dbe->book1D("HtMiss", "MHT", R7BINS, R7MIN, R7MAX);
00390 l1GctHtMissPhi_ = dbe->book1D("HtMissPhi", "MHT #phi", MHTPHIBINS, MHTPHIMIN, MHTPHIMAX);
00391 l1GctHtMissOf_ = dbe->book1D("HtMissOf", "MHT OVERFLOW", OFBINS, OFMIN, OFMAX);
00392 l1GctHtMissOccBx_ = dbe->book2D("HtMissOccBx","MHT PER BX",BXBINS,BXMIN,BXMAX,R7BINS,R7MIN,R7MAX);
00393 l1GctEtMissHtMissCorr_ = dbe->book2D("EtMissHtMissCorr", "MET MHT CORRELATION",
00394 R6BINS, R12MIN, R12MAX,
00395 R6BINS, R7MIN, R7MAX);
00396 l1GctEtMissHtMissCorrPhi_ = dbe->book2D("EtMissHtMissPhiCorr", "MET MHT #phi CORRELATION",
00397 METPHIBINS, METPHIMIN, METPHIMAX,
00398 MHTPHIBINS, MHTPHIMIN, MHTPHIMAX);
00399 l1GctEtTotal_ = dbe->book1D("EtTotal", "SUM E_{T}", R12BINS, R12MIN, R12MAX);
00400 l1GctEtTotalOf_ = dbe->book1D("EtTotalOf", "SUM E_{T} OVERFLOW", OFBINS, OFMIN, OFMAX);
00401 l1GctEtTotalOccBx_ = dbe->book2D("EtTotalOccBx","SUM E_{T} PER BX",BXBINS,BXMIN,BXMAX,R12BINS,R12MIN,R12MAX);
00402 l1GctEtHad_ = dbe->book1D("EtHad", "H_{T}", R12BINS, R12MIN, R12MAX);
00403 l1GctEtHadOf_ = dbe->book1D("EtHadOf", "H_{T} OVERFLOW", OFBINS, OFMIN, OFMAX);
00404 l1GctEtHadOccBx_ = dbe->book2D("EtHadOccBx","H_{T} PER BX",BXBINS,BXMIN,BXMAX,R12BINS,R12MIN,R12MAX);
00405 l1GctEtTotalEtHadCorr_ = dbe->book2D("EtTotalEtHadCorr", "Sum E_{T} H_{T} CORRELATION",
00406 R6BINS, R12MIN, R12MAX,
00407 R6BINS, R12MIN, R12MAX);
00408 }
00409
00410 }
00411
00412
00413 void L1TGCT::endJob(void)
00414 {
00415 if (verbose_)
00416 edm::LogInfo("L1TGCT") << "L1TGCT: end job...." << std::endl;
00417 edm::LogInfo("EndJob") << "analyzed " << nev_ << " events";
00418
00419 if (outputFile_.size() != 0 && dbe) {
00420 dbe->save(outputFile_);
00421 }
00422
00423 return;
00424 }
00425
00426 void L1TGCT::analyze(const edm::Event & e, const edm::EventSetup & c)
00427 {
00428 nev_++;
00429 if (verbose_) {
00430 edm::LogInfo("L1TGCT") << "L1TGCT: analyze...." << std::endl;
00431 }
00432
00433
00434
00435
00436
00437
00438
00439
00440
00441
00442
00443
00444
00445
00446
00447 double triggerType = static_cast<double> (e.experimentType()) + 0.001;
00448 double triggerTypeLast = static_cast<double> (edm::EventAuxiliary::ExperimentType::ErrorTrigger)
00449 + 0.001;
00450 triggerType_->Fill(triggerType);
00451 triggerType_->Fill(triggerTypeLast + 1);
00452
00453
00454 if (filterTriggerType_ >= 0) {
00455
00456
00457 if (e.isRealData()) {
00458 if (!(e.experimentType() == filterTriggerType_)) {
00459
00460 edm::LogInfo("L1TGCT") << "\n Event of TriggerType "
00461 << e.experimentType() << " rejected" << std::endl;
00462 return;
00463
00464 }
00465 }
00466
00467 }
00468
00469
00470 edm::Handle < L1GctEmCandCollection > l1IsoEm;
00471 edm::Handle < L1GctEmCandCollection > l1NonIsoEm;
00472 edm::Handle < L1GctJetCandCollection > l1CenJets;
00473 edm::Handle < L1GctJetCandCollection > l1ForJets;
00474 edm::Handle < L1GctJetCandCollection > l1TauJets;
00475 edm::Handle < L1GctHFRingEtSumsCollection > l1HFSums;
00476 edm::Handle < L1GctHFBitCountsCollection > l1HFCounts;
00477 edm::Handle < L1GctEtMissCollection > l1EtMiss;
00478 edm::Handle < L1GctHtMissCollection > l1HtMiss;
00479 edm::Handle < L1GctEtHadCollection > l1EtHad;
00480 edm::Handle < L1GctEtTotalCollection > l1EtTotal;
00481
00482 e.getByLabel(gctIsoEmSource_, l1IsoEm);
00483 e.getByLabel(gctNonIsoEmSource_, l1NonIsoEm);
00484 e.getByLabel(gctCenJetsSource_, l1CenJets);
00485 e.getByLabel(gctForJetsSource_, l1ForJets);
00486 e.getByLabel(gctTauJetsSource_, l1TauJets);
00487 e.getByLabel(gctEnergySumsSource_, l1HFSums);
00488 e.getByLabel(gctEnergySumsSource_, l1HFCounts);
00489 e.getByLabel(gctEnergySumsSource_, l1EtMiss);
00490 e.getByLabel(gctEnergySumsSource_, l1HtMiss);
00491 e.getByLabel(gctEnergySumsSource_, l1EtHad);
00492 e.getByLabel(gctEnergySumsSource_, l1EtTotal);
00493
00494
00495
00496
00497
00498 if (l1CenJets.isValid()) {
00499 for (L1GctJetCandCollection::const_iterator cj = l1CenJets->begin();cj != l1CenJets->end(); cj++) {
00500
00501 if (cj->bx()==0) {
00502 l1GctCenJetsRank_->Fill(cj->rank());
00503
00504 if (cj->rank()) {
00505 l1GctAllJetsEtEtaPhi_->Fill(cj->regionId().ieta(),cj->regionId().iphi(),cj->rank());
00506 l1GctAllJetsOccEtaPhi_->Fill(cj->regionId().ieta(),cj->regionId().iphi());
00507 l1GctCenJetsEtEtaPhi_->Fill(cj->regionId().ieta(),cj->regionId().iphi(),cj->rank());
00508 l1GctCenJetsOccEtaPhi_->Fill(cj->regionId().ieta(),cj->regionId().iphi());
00509 }
00510 }
00511 if (cj->rank()) l1GctAllJetsOccRankBx_->Fill(cj->bx(),cj->rank());
00512 }
00513 } else {
00514 edm::LogWarning("DataNotFound") << " Could not find l1CenJets label was " << gctCenJetsSource_ ;
00515 }
00516
00517
00518 if (l1ForJets.isValid()) {
00519 for (L1GctJetCandCollection::const_iterator fj = l1ForJets->begin(); fj != l1ForJets->end(); fj++) {
00520
00521 if (fj->bx()==0) {
00522 l1GctForJetsRank_->Fill(fj->rank());
00523
00524 if (fj->rank()) {
00525 l1GctAllJetsEtEtaPhi_->Fill(fj->regionId().ieta(),fj->regionId().iphi(),fj->rank());
00526 l1GctAllJetsOccEtaPhi_->Fill(fj->regionId().ieta(),fj->regionId().iphi());
00527 l1GctForJetsEtEtaPhi_->Fill(fj->regionId().ieta(),fj->regionId().iphi(),fj->rank());
00528 l1GctForJetsOccEtaPhi_->Fill(fj->regionId().ieta(),fj->regionId().iphi());
00529 }
00530 }
00531 if (fj->rank()) l1GctAllJetsOccRankBx_->Fill(fj->bx(),fj->rank());
00532 }
00533 } else {
00534 edm::LogWarning("DataNotFound") << " Could not find l1ForJets label was " << gctForJetsSource_ ;
00535 }
00536
00537
00538 if (l1TauJets.isValid()) {
00539 for (L1GctJetCandCollection::const_iterator tj = l1TauJets->begin(); tj != l1TauJets->end(); tj++) {
00540
00541 if (tj->bx()==0) {
00542 l1GctTauJetsRank_->Fill(tj->rank());
00543
00544 if (tj->rank()) {
00545 l1GctTauJetsEtEtaPhi_->Fill(tj->regionId().ieta(),tj->regionId().iphi(),tj->rank());
00546 l1GctTauJetsOccEtaPhi_->Fill(tj->regionId().ieta(),tj->regionId().iphi());
00547 }
00548 }
00549 if (tj->rank()) l1GctAllJetsOccRankBx_->Fill(tj->bx(),tj->rank());
00550 }
00551 } else {
00552 edm::LogWarning("DataNotFound") << " Could not find l1TauJets label was " << gctTauJetsSource_ ;
00553 }
00554
00555
00556 if (l1EtMiss.isValid()) {
00557 for (L1GctEtMissCollection::const_iterator met = l1EtMiss->begin(); met != l1EtMiss->end(); met++) {
00558
00559 if (met->bx()==0) {
00560 if (met->overFlow() == 0 && met->et() > 0) {
00561
00562 l1GctEtMiss_->Fill(met->et());
00563 l1GctEtMissPhi_->Fill(met->phi());
00564 }
00565 l1GctEtMissOf_->Fill(met->overFlow());
00566 }
00567 if (met->overFlow() == 0 && met->et() > 0) l1GctEtMissOccBx_->Fill(met->bx(),met->et());
00568 }
00569 } else {
00570 edm::LogWarning("DataNotFound") << " Could not find l1EtMiss label was " << gctEnergySumsSource_ ;
00571 }
00572
00573
00574 if (l1HtMiss.isValid()) {
00575 for (L1GctHtMissCollection::const_iterator mht = l1HtMiss->begin(); mht != l1HtMiss->end(); mht++) {
00576
00577 if (mht->bx()==0) {
00578 if (mht->overFlow() == 0 && mht->et() > 0) {
00579
00580 l1GctHtMiss_->Fill(mht->et());
00581 l1GctHtMissPhi_->Fill(mht->phi());
00582 }
00583 l1GctHtMissOf_->Fill(mht->overFlow());
00584 }
00585 if (mht->overFlow() == 0 && mht->et() > 0) l1GctHtMissOccBx_->Fill(mht->bx(),mht->et());
00586 }
00587 } else {
00588 edm::LogWarning("DataNotFound") << " Could not find l1HtMiss label was " << gctEnergySumsSource_ ;
00589 }
00590
00591
00592 if (l1HtMiss.isValid() && l1EtMiss.isValid()) {
00593 if (l1HtMiss->size() == l1EtMiss->size()) {
00594 for (unsigned i=0; i<l1HtMiss->size(); i++) {
00595 if (l1HtMiss->at(i).overFlow() == 0 && l1EtMiss->at(i).overFlow() == 0 &&
00596 l1HtMiss->at(i).bx() == 0 && l1EtMiss->at(i).bx() == 0) {
00597
00598 l1GctEtMissHtMissCorr_->Fill(l1EtMiss->at(i).et(),l1HtMiss->at(i).et());
00599 if (l1HtMiss->at(i).et() && l1EtMiss->at(i).et()){
00600 l1GctEtMissHtMissCorrPhi_->Fill(l1EtMiss->at(i).phi(),l1HtMiss->at(i).phi());
00601 }
00602 }
00603 }
00604 }
00605 } else {
00606 edm::LogWarning("DataNotFound") << " Could not find l1EtMiss or l1HtMiss label was " << gctEnergySumsSource_ ;
00607 }
00608
00609
00610 if (l1EtHad.isValid()) {
00611 for (L1GctEtHadCollection::const_iterator ht = l1EtHad->begin(); ht != l1EtHad->end(); ht++) {
00612
00613 if (ht->bx()==0) {
00614 l1GctEtHad_->Fill(ht->et());
00615 l1GctEtHadOf_->Fill(ht->overFlow());
00616 }
00617 l1GctEtHadOccBx_->Fill(ht->bx(),ht->et());
00618 }
00619 } else {
00620 edm::LogWarning("DataNotFound") << " Could not find l1EtHad label was " << gctEnergySumsSource_ ;
00621 }
00622
00623
00624 if (l1EtTotal.isValid()) {
00625 for (L1GctEtTotalCollection::const_iterator et = l1EtTotal->begin(); et != l1EtTotal->end(); et++) {
00626
00627 if (et->bx()==0) {
00628 l1GctEtTotal_->Fill(et->et());
00629 l1GctEtTotalOf_->Fill(et->overFlow());
00630 }
00631 l1GctEtTotalOccBx_->Fill(et->bx(),et->et());
00632 }
00633 } else {
00634 edm::LogWarning("DataNotFound") << " Could not find l1EtTotal label was " << gctEnergySumsSource_ ;
00635 }
00636
00637
00638 if (l1EtTotal.isValid() && l1EtHad.isValid()) {
00639 if (l1EtTotal->size() == l1EtHad->size()) {
00640 for (unsigned i=0; i<l1EtHad->size(); i++) {
00641 if (l1EtHad->at(i).overFlow() == 0 && l1EtTotal->at(i).overFlow() == 0 &&
00642 l1EtHad->at(i).bx() == 0 && l1EtTotal->at(i).bx() == 0) {
00643
00644 l1GctEtTotalEtHadCorr_->Fill(l1EtTotal->at(i).et(),l1EtHad->at(i).et());
00645 }
00646 }
00647 }
00648 } else {
00649 edm::LogWarning("DataNotFound") << " Could not find l1EtTotal or l1EtHad label was " << gctEnergySumsSource_ ;
00650 }
00651
00652
00653 if (l1HFSums.isValid()) {
00654 for (L1GctHFRingEtSumsCollection::const_iterator hfs=l1HFSums->begin(); hfs!=l1HFSums->end(); hfs++){
00655
00656 if (hfs->bx()==0) {
00657
00658 l1GctHFRing1ETSumPosEta_->Fill(hfs->etSum(0));
00659 l1GctHFRing1ETSumNegEta_->Fill(hfs->etSum(1));
00660 l1GctHFRing2ETSumPosEta_->Fill(hfs->etSum(2));
00661 l1GctHFRing2ETSumNegEta_->Fill(hfs->etSum(3));
00662
00663 if (hfs->etSum(2)!=0) l1GctHFRingRatioPosEta_->Fill((hfs->etSum(0))/(hfs->etSum(2)));
00664 if (hfs->etSum(3)!=0) l1GctHFRingRatioNegEta_->Fill((hfs->etSum(1))/(hfs->etSum(3)));
00665
00666 l1GctHFRing1PosEtaNegEta_->Fill(hfs->etSum(0),hfs->etSum(1));
00667 l1GctHFRing2PosEtaNegEta_->Fill(hfs->etSum(2),hfs->etSum(3));
00668 }
00669
00670 for (unsigned i=0; i<4; i++){
00671 l1GctHFRingETSumOccBx_->Fill(hfs->bx(),hfs->etSum(i));
00672 }
00673 }
00674 } else {
00675 edm::LogWarning("DataNotFound") << " Could not find l1HFSums label was " << gctEnergySumsSource_ ;
00676 }
00677
00678
00679 if (l1HFCounts.isValid()) {
00680 for (L1GctHFBitCountsCollection::const_iterator hfc=l1HFCounts->begin(); hfc!=l1HFCounts->end(); hfc++){
00681
00682 if (hfc->bx()==0) {
00683
00684 l1GctHFRing1TowerCountPosEta_->Fill(hfc->bitCount(0));
00685 l1GctHFRing1TowerCountNegEta_->Fill(hfc->bitCount(1));
00686 l1GctHFRing2TowerCountPosEta_->Fill(hfc->bitCount(2));
00687 l1GctHFRing2TowerCountNegEta_->Fill(hfc->bitCount(3));
00688
00689 l1GctHFRing1TowerCountPosEtaNegEta_->Fill(hfc->bitCount(0),hfc->bitCount(1));
00690 l1GctHFRing2TowerCountPosEtaNegEta_->Fill(hfc->bitCount(2),hfc->bitCount(3));
00691 }
00692
00693 for (unsigned i=0; i<4; i++){
00694 l1GctHFRingTowerCountOccBx_->Fill(hfc->bx(),hfc->bitCount(i));
00695 }
00696 }
00697 } else {
00698 edm::LogWarning("DataNotFound") << " Could not find l1HFCounts label was " << gctEnergySumsSource_ ;
00699 }
00700
00701
00702 if (l1IsoEm.isValid()) {
00703 for (L1GctEmCandCollection::const_iterator ie=l1IsoEm->begin(); ie!=l1IsoEm->end(); ie++) {
00704
00705 if (ie->bx()==0) {
00706 l1GctIsoEmRank_->Fill(ie->rank());
00707
00708 if (ie->rank()){
00709 l1GctIsoEmRankEtaPhi_->Fill(ie->regionId().ieta(),ie->regionId().iphi(),ie->rank());
00710 l1GctIsoEmOccEtaPhi_->Fill(ie->regionId().ieta(),ie->regionId().iphi());
00711 }
00712 }
00713 if (ie->rank()) l1GctAllEmOccRankBx_->Fill(ie->bx(),ie->rank());
00714 }
00715 } else {
00716 edm::LogWarning("DataNotFound") << " Could not find l1IsoEm label was " << gctIsoEmSource_ ;
00717 }
00718
00719
00720 if (l1NonIsoEm.isValid()) {
00721 for (L1GctEmCandCollection::const_iterator ne=l1NonIsoEm->begin(); ne!=l1NonIsoEm->end(); ne++) {
00722
00723 if (ne->bx()==0) {
00724 l1GctNonIsoEmRank_->Fill(ne->rank());
00725
00726 if (ne->rank()){
00727 l1GctNonIsoEmRankEtaPhi_->Fill(ne->regionId().ieta(),ne->regionId().iphi(),ne->rank());
00728 l1GctNonIsoEmOccEtaPhi_->Fill(ne->regionId().ieta(),ne->regionId().iphi());
00729 }
00730 }
00731 if (ne->rank()) l1GctAllEmOccRankBx_->Fill(ne->bx(),ne->rank());
00732 }
00733 } else {
00734 edm::LogWarning("DataNotFound") << " Could not find l1NonIsoEm label was " << gctNonIsoEmSource_ ;
00735 }
00736 }
00737
00738