Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2022-01-05 23:13:01

0001 // -*- C++ -*-
0002 //
0003 // Package:    L1GctTest
0004 // Class:      L1GctTest
0005 //
0006 /**\class L1GctTest L1GctTest.cc L1Trigger/GlobalCaloTrigger/test/L1GctTest.cc
0007 
0008  Description: a collection of GCT tests
0009 
0010 */
0011 //
0012 // Original Author:  Gregory Heath
0013 //         Created:  Mon Mar 12 16:36:35 CET 2007
0014 //
0015 //
0016 
0017 // system include files
0018 #include <memory>
0019 
0020 // user include files
0021 #include "FWCore/Framework/interface/Frameworkfwd.h"
0022 #include "FWCore/Framework/interface/one/EDAnalyzer.h"
0023 
0024 #include "FWCore/Framework/interface/Event.h"
0025 #include "FWCore/Framework/interface/MakerMacros.h"
0026 
0027 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0028 
0029 #include "L1Trigger/GlobalCaloTrigger/interface/L1GlobalCaloTrigger.h"
0030 
0031 class gctTestFunctions;
0032 
0033 //
0034 // class declaration
0035 //
0036 class L1GctJetFinderParamsRcd;
0037 class L1GctChannelMaskRcd;
0038 class L1JetEtScaleRcd;
0039 class L1HtMissScaleRcd;
0040 class L1HfRingEtScaleRcd;
0041 
0042 class L1GctTest : public edm::one::EDAnalyzer<> {
0043 public:
0044   /// typedefs
0045   typedef L1GlobalCaloTrigger::lutPtr lutPtr;
0046   typedef L1GlobalCaloTrigger::lutPtrVector lutPtrVector;
0047 
0048   explicit L1GctTest(const edm::ParameterSet&);
0049   ~L1GctTest();
0050 
0051 private:
0052   virtual void beginJob();
0053   virtual void analyze(const edm::Event& e, const edm::EventSetup& c);
0054   virtual void endJob();
0055 
0056   void configureGct(const edm::EventSetup& c);
0057   void configParamsPrint(std::ostream& out);
0058 
0059   // ----------member data ---------------------------
0060 
0061   L1GlobalCaloTrigger* m_gct;
0062   lutPtrVector m_jetEtCalibLuts;
0063 
0064   std::unique_ptr<gctTestFunctions> m_tester;
0065 
0066   edm::ESGetToken<L1GctJetFinderParams, L1GctJetFinderParamsRcd> m_jfParsToken;
0067   edm::ESGetToken<L1GctChannelMask, L1GctChannelMaskRcd> m_chanMaskToken;
0068   edm::ESGetToken<L1CaloEtScale, L1JetEtScaleRcd> m_etScaleToken;
0069   edm::ESGetToken<L1CaloEtScale, L1HtMissScaleRcd> m_htMissScaleToken;
0070   edm::ESGetToken<L1CaloEtScale, L1HfRingEtScaleRcd> m_hfRingEtScaleToken;
0071 
0072   bool theElectronTestIsEnabled;
0073   bool theSingleEventTestIsEnabled;
0074   bool theEnergyAlgosTestIsEnabled;
0075   bool theFirmwareTestIsEnabled;
0076   bool theRealDataTestIsEnabled;
0077 
0078   bool theUseNewTauAlgoFlag;
0079   bool theConfigParamsPrintFlag;
0080 
0081   std::string theInputDataFileName;
0082   std::string theReferenceDataFileName;
0083   std::string theEnergySumsDataFileName;
0084 
0085   int m_firstBx;
0086   int m_lastBx;
0087 
0088   unsigned m_eventNo;
0089   bool m_allGood;
0090 };