File indexing completed on 2024-04-06 12:08:53
0001
0002
0003
0004
0005
0006
0007
0008
0009 #include "FWCore/Framework/interface/ESHandle.h"
0010 #include "FWCore/Framework/interface/Event.h"
0011 #include "FWCore/Framework/interface/EventSetup.h"
0012 #include "FWCore/Framework/interface/Run.h"
0013 #include "FWCore/MessageLogger/interface/MessageLogger.h"
0014 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0015 #include "FWCore/ServiceRegistry/interface/Service.h"
0016
0017 #include "DQM/SiStripMonitorSummary/interface/SiStripClassToMonitorCondData.h"
0018 #include "SiStripMonitorCondDataOnDemandExample.h"
0019
0020 #include "TH1F.h"
0021 #include "TH2F.h"
0022 #include "TProfile.h"
0023
0024
0025 #include <algorithm>
0026 #include <cmath>
0027 #include <cstdlib>
0028 #include <numeric>
0029 #include <string>
0030
0031
0032
0033
0034 SiStripMonitorCondDataOnDemandExample::SiStripMonitorCondDataOnDemandExample(edm::ParameterSet const &iConfig) {
0035 condDataMonitoring_ = std::make_unique<SiStripClassToMonitorCondData>(iConfig, consumesCollector());
0036 }
0037
0038
0039
0040
0041
0042 void SiStripMonitorCondDataOnDemandExample::beginRun(edm::Run const &run, edm::EventSetup const &eSetup) {
0043 eventCounter_ = 0;
0044 condDataMonitoring_->beginRun(run.run(), eSetup);
0045 }
0046
0047
0048
0049
0050
0051 void SiStripMonitorCondDataOnDemandExample::beginJob(void) {}
0052
0053
0054
0055
0056 void SiStripMonitorCondDataOnDemandExample::analyze(edm::Event const &iEvent, edm::EventSetup const &eSetup) {
0057
0058
0059
0060
0061
0062
0063
0064
0065
0066
0067
0068
0069
0070
0071
0072 condDataMonitoring_->getLayerMEsOnDemand(eSetup, "TEC", 2, 4);
0073
0074 }
0075
0076
0077
0078
0079
0080 void SiStripMonitorCondDataOnDemandExample::endRun(edm::Run const &run, edm::EventSetup const &eSetup) {
0081 condDataMonitoring_->save();
0082
0083 }
0084
0085
0086
0087
0088
0089 void SiStripMonitorCondDataOnDemandExample::endJob(void) {}
0090
0091 #include "FWCore/Framework/interface/MakerMacros.h"
0092 DEFINE_FWK_MODULE(SiStripMonitorCondDataOnDemandExample);