74 edm::LogInfo(
"SUSY_HLT_DiJet_MET") <<
"SUSY_HLT_DiJet_MET::analyze" << std::endl;
82 if ( !pfMETCollection.
isValid() ){
83 edm::LogError (
"SUSY_HLT_DiJet_MET") <<
"invalid collection: PFMET" <<
"\n";
88 if ( !caloMETCollection.
isValid() ){
89 edm::LogError (
"SUSY_HLT_DiJet_MET") <<
"invalid collection: CaloMET" <<
"\n";
97 if ( !pfJetCollection.
isValid() ){
98 edm::LogError (
"SUSY_HLT_DiJet_MET") <<
"invalid collection: PFJets" <<
"\n";
103 if ( !caloJetCollection.
isValid() ){
104 edm::LogError (
"SUSY_HLT_DiJet_MET") <<
"invalid collection: CaloJets" <<
"\n";
114 edm::LogError (
"SUSY_HLT_DiJet_MET") <<
"invalid collection: TriggerResults" <<
"\n";
119 if(!triggerSummary.
isValid()) {
120 edm::LogError (
"SUSY_HLT_DiJet_MET") <<
"invalid collection: TriggerSummary" <<
"\n";
131 if( !(filterIndex >= triggerSummary->
sizeFilters()) ){
133 for(
size_t j = 0; j < keys.size(); ++j ){
140 std::vector<float> ptJet, etaJet, phiJet;
141 if( !(jetFilterIndex >= triggerSummary->
sizeFilters()) ){
143 for(
size_t j = 0; j < keys_jetfilter.size(); ++j ){
149 ptJet.push_back(foundObject.
pt());
150 etaJet.push_back(foundObject.
eta());
151 phiJet.push_back(foundObject.
phi());
157 bool hasFired =
false;
158 bool hasFiredAuxiliaryForHadronicLeg =
false;
160 unsigned int numTriggers = trigNames.
size();
161 for(
unsigned int hltIndex=0; hltIndex<numTriggers; ++hltIndex ){
168 if(hasFiredAuxiliaryForHadronicLeg) {
170 int offlineJetCounter = 0;
171 int offlineCentralJets = 0;
172 int nMatch = 0, jet1Index = -1, jet2Index = -1;
174 for (reco::PFJetCollection::const_iterator i_pfjet = pfJetCollection->begin(); i_pfjet != pfJetCollection->end(); ++i_pfjet){
177 offlineCentralJets++;
180 for(
unsigned int itrigjet = 0; itrigjet < ptJet.size(); ++itrigjet) {
181 if(itrigjet < 2 && (
sqrt((i_pfjet->phi()-phiJet.at(itrigjet))*(i_pfjet->phi()-phiJet.at(itrigjet)) + (i_pfjet->eta()-etaJet.at(itrigjet))*(i_pfjet->eta()-etaJet.at(itrigjet))) < 0.4)) {
183 if(nMatch == 1) jet1Index = offlineJetCounter;
184 if(nMatch == 2) jet2Index = offlineJetCounter;
206 if(jet1Index > -1 && jet2Index > -1) {
constexpr double deltaPhi(double phi1, double phi2)
bool wasrun() const
Was at least one path run?
MonitorElement * h_triggerJetEta
trigger::size_type sizeFilters() const
edm::InputTag triggerFilter_
edm::EDGetTokenT< reco::CaloJetCollection > theCaloJetCollection_
MonitorElement * h_pfMetTurnOn_num
MonitorElement * h_pfMetPhi
MonitorElement * h_pfJetPt
bool accept() const
Has at least one path accepted the event?
const Keys & filterKeys(trigger::size_type index) const
trigger::size_type filterIndex(const edm::InputTag &filterTag) const
find index of filter in data-member vector from filter tag
MonitorElement * h_caloMetvsPFMet
MonitorElement * h_pfJetEta
Strings::size_type size() const
MonitorElement * h_triggerMetPhi
Single trigger physics object (e.g., an isolated muon)
edm::EDGetTokenT< reco::PFMETCollection > thePfMETCollection_
const TriggerObjectCollection & getObjects() const
MonitorElement * h_triggerMet
void Fill(HcalDetId &id, double val, std::vector< TH2F > &depth)
MonitorElement * h_pfJet2PtTurnOn_den
MonitorElement * h_pfJet1Jet2DPhi
std::vector< TriggerObject > TriggerObjectCollection
collection of trigger physics objects (e.g., all isolated muons)
static const char *const trigNames[]
MonitorElement * h_pfJetPhi
edm::InputTag triggerJetFilter_
std::string const & triggerName(unsigned int index) const
std::vector< size_type > Keys
MonitorElement * h_pfJet2PtTurnOn_num
edm::EDGetTokenT< reco::PFJetCollection > thePfJetCollection_
edm::EDGetTokenT< edm::TriggerResults > triggerResults_
edm::EDGetTokenT< reco::CaloMETCollection > theCaloMETCollection_
std::string triggerPathAuxiliaryForHadronic_
MonitorElement * h_pfMetTurnOn_den
edm::EDGetTokenT< trigger::TriggerEvent > theTrigSummary_
MonitorElement * h_triggerJetPt
MonitorElement * h_triggerJetPhi