00001 #ifndef HLTfilters_HLTLevel1GTSeed_h 00002 #define HLTfilters_HLTLevel1GTSeed_h 00003 00022 // system include files 00023 #include <string> 00024 #include <vector> 00025 00026 // user include files 00027 00028 // base class 00029 #include "HLTrigger/HLTcore/interface/HLTFilter.h" 00030 00031 #include "DataFormats/HLTReco/interface/TriggerFilterObjectWithRefs.h" 00032 00033 #include "DataFormats/L1GlobalTrigger/interface/L1GlobalTriggerReadoutSetupFwd.h" 00034 #include "CondFormats/L1TObjects/interface/L1GtTriggerMenuFwd.h" 00035 #include "DataFormats/L1GlobalTrigger/interface/L1GtLogicParser.h" 00036 00037 #include "FWCore/Utilities/interface/InputTag.h" 00038 00039 // forward declarations 00040 class L1GtTriggerMenu; 00041 class L1GtTriggerMask; 00042 class L1GlobalTriggerReadoutRecord; 00043 00044 // class declaration 00045 class HLTLevel1GTSeed : public HLTFilter 00046 { 00047 00048 public: 00049 00051 explicit HLTLevel1GTSeed(const edm::ParameterSet&); 00052 00054 virtual ~HLTLevel1GTSeed(); 00055 00057 virtual bool filter(edm::Event&, const edm::EventSetup&); 00058 00059 private: 00060 00062 const std::vector<L1GtObject>* objectTypeVec(const int chipNumber, const std::string& cndName); 00063 00066 void updateAlgoLogicParser(const L1GtTriggerMenu*, const AlgorithmMap&); 00067 00070 void updateAlgoLogicParser(const std::vector<bool>& gtWord, 00071 const std::vector<unsigned int>& triggerMask, const int physicsDaqPartition); 00072 00075 void convertStringToBitNumber(); 00076 00079 void debugPrint(bool); 00080 00082 bool seedsL1TriggerObjectMaps(edm::Event&, std::auto_ptr< 00083 trigger::TriggerFilterObjectWithRefs>&, 00084 const L1GlobalTriggerReadoutRecord*, const int physicsDaqPartition); 00085 00091 bool seedsL1Extra(edm::Event&, std::auto_ptr<trigger::TriggerFilterObjectWithRefs>&); 00092 00094 void dumpTriggerFilterObjectWithRefs(std::auto_ptr<trigger::TriggerFilterObjectWithRefs>&); 00095 00096 00097 private: 00098 00099 // cached stuff 00100 00102 const L1GtTriggerMenu* m_l1GtMenu; 00103 unsigned long long m_l1GtMenuCacheID; 00104 00106 const L1GtTriggerMask* m_l1GtTmAlgo; 00107 unsigned long long m_l1GtTmAlgoCacheID; 00108 00109 const L1GtTriggerMask* m_l1GtTmTech; 00110 unsigned long long m_l1GtTmTechCacheID; 00111 00112 std::vector<unsigned int> m_triggerMaskAlgoTrig; 00113 std::vector<unsigned int> m_triggerMaskTechTrig; 00114 00115 // 00116 00118 L1GtLogicParser m_l1AlgoLogicParser; 00119 00121 std::vector<L1GtLogicParser::OperandToken> m_l1AlgoSeeds; 00122 00124 std::vector< const std::vector<L1GtLogicParser::TokenRPN>* > m_l1AlgoSeedsRpn; 00125 00127 std::vector< std::vector< const std::vector<L1GtObject>* > > m_l1AlgoSeedsObjType; 00128 00129 00130 private: 00131 00140 bool m_l1UseL1TriggerObjectMaps; 00141 00144 int m_l1NrBxInEvent; 00145 00147 bool m_l1TechTriggerSeeding; 00148 00150 bool m_l1UseAliasesForSeeding; 00151 00154 std::string m_l1SeedsLogicalExpression; 00155 00157 edm::InputTag m_l1GtReadoutRecordTag; 00158 00160 edm::InputTag m_l1GtObjectMapTag; 00161 00163 edm::InputTag m_l1CollectionsTag; 00164 00166 edm::InputTag m_l1MuonCollectionTag; 00167 00169 edm::InputTag m_l1MuonTag; 00170 edm::InputTag m_l1ExtraTag; 00171 edm::InputTag m_l1IsoEGTag; 00172 edm::InputTag m_l1NoIsoEGTag; 00173 edm::InputTag m_l1CenJetTag; 00174 edm::InputTag m_l1ForJetTag; 00175 edm::InputTag m_l1TauJetTag; 00176 edm::InputTag m_l1EtMissMET; 00177 edm::InputTag m_l1EtMissMHT; 00178 00180 bool saveTags_; 00181 00183 bool m_isDebugEnabled; 00184 00185 00186 }; 00187 00188 #endif // HLTfilters_HLTLevel1GTSeed_h