File indexing completed on 2024-04-06 12:18:22
0001 #include <iostream>
0002
0003 #include "CondFormats/DataRecord/interface/L1TUtmTriggerMenuRcd.h"
0004 #include "CondFormats/L1TObjects/interface/L1TUtmAlgorithm.h"
0005 #include "CondFormats/L1TObjects/interface/L1TUtmTriggerMenu.h"
0006 #include "DataFormats/Common/interface/Handle.h"
0007 #include "DataFormats/L1TGlobal/interface/GlobalAlgBlk.h"
0008 #include "DataFormats/L1TGlobal/interface/GlobalExtBlk.h"
0009 #include "FWCore/Framework/interface/one/EDAnalyzer.h"
0010 #include "FWCore/Framework/interface/Event.h"
0011 #include "FWCore/Framework/interface/EventSetup.h"
0012 #include "FWCore/Framework/interface/Frameworkfwd.h"
0013 #include "FWCore/Framework/interface/MakerMacros.h"
0014 #include "FWCore/ParameterSet/interface/Registry.h"
0015 #include "SimDataFormats/GeneratorProducts/interface/GenEventInfoProduct.h"
0016 #include "SimDataFormats/PileupSummaryInfo/interface/PileupSummaryInfo.h"
0017
0018 #include "EventHeader.h"
0019 #include "HLTInfo.h"
0020 #include "HLTMCtruth.h"
0021 #include "RECOVertex.h"
0022
0023
0024
0025
0026
0027
0028
0029
0030
0031
0032
0033
0034 class HLTBitAnalyzer : public edm::one::EDAnalyzer<edm::one::WatchRuns> {
0035 public:
0036 explicit HLTBitAnalyzer(edm::ParameterSet const& conf);
0037 void analyze(edm::Event const& e, edm::EventSetup const& iSetup) override;
0038 void endJob() override;
0039 void beginRun(edm::Run const&, edm::EventSetup const&) override;
0040 void endRun(edm::Run const&, edm::EventSetup const&) override {}
0041
0042
0043
0044
0045 TTree* HltTree;
0046
0047 private:
0048
0049
0050
0051
0052 EventHeader evt_header_;
0053 HLTInfo hlt_analysis_;
0054
0055 HLTMCtruth mct_analysis_;
0056 RECOVertex vrt_analysisOffline0_;
0057
0058 edm::InputTag hltresults_, genEventInfo_;
0059
0060
0061
0062
0063
0064
0065
0066
0067
0068
0069
0070
0071
0072
0073 edm::InputTag l1results_;
0074
0075 edm::InputTag mctruth_, simhits_;
0076 edm::InputTag VertexTagOffline0_;
0077 edm::InputTag pileupInfo_;
0078
0079 edm::EDGetTokenT<edm::TriggerResults> hltresultsToken_;
0080 edm::EDGetTokenT<GenEventInfoProduct> genEventInfoToken_;
0081
0082 edm::EDGetTokenT<GlobalAlgBlkBxCollection> l1resultsToken_;
0083
0084
0085
0086
0087
0088
0089
0090
0091
0092
0093
0094 edm::EDGetTokenT<reco::CandidateView> mctruthToken_;
0095 edm::EDGetTokenT<std::vector<SimTrack> > simtracksToken_;
0096 edm::EDGetTokenT<std::vector<SimVertex> > simverticesToken_;
0097 edm::EDGetTokenT<std::vector<PileupSummaryInfo> > pileupInfoToken_;
0098 edm::EDGetTokenT<reco::VertexCollection> VertexTagOffline0Token_;
0099
0100 int errCnt;
0101 static int errMax() { return 5; }
0102
0103 std::string _HistName;
0104 double _EtaMin, _EtaMax;
0105 TFile* m_file;
0106 bool _UseTFileService;
0107 bool _isData;
0108
0109 double ptHat, weight;
0110 };