58 edm::LogInfo(
"HotlineDQM") <<
"HotlineDQM::analyze" << std::endl;
65 if ( !pfMETCollection.
isValid() ){
66 edm::LogError (
"HotlineDQM") <<
"invalid collection: PFMET" <<
"\n";
71 if ( !caloMETCollection.
isValid() ){
72 edm::LogError (
"HotlineDQM") <<
"invalid collection: CaloMET" <<
"\n";
81 if ( !caloJetCollection.
isValid() ){
82 edm::LogError (
"HotlineDQM") <<
"invalid collection: CaloJets" <<
"\n";
91 if ( !MuonCollection.
isValid() ){
92 edm::LogError (
"HotlineDQM") <<
"invalid collection: Muons " <<
"\n";
101 if ( !PhotonCollection.
isValid() ){
102 edm::LogError (
"HotlineDQM") <<
"invalid collection: Photons " <<
"\n";
112 edm::LogError (
"HotlineDQM") <<
"invalid collection: TriggerResults" <<
"\n";
117 if(!triggerSummary.
isValid()) {
118 edm::LogError (
"HotlineDQM") <<
"invalid collection: TriggerSummary" <<
"\n";
122 bool hasFired =
false;
124 unsigned int numTriggers = trigNames.
size();
125 for(
unsigned int hltIndex=0; hltIndex<numTriggers; ++hltIndex ){
132 float ptMuon=-1, ptPhoton=-1,
met=-1,
pfMet=-1, ht = 0;
135 if( !(filterIndex >= triggerSummary->
sizeFilters()) ){
137 for(
unsigned short key : keys){
140 if(foundObject.
pt() > ptMuon) ptMuon = foundObject.
pt();
143 if(foundObject.
pt() > ptPhoton) ptPhoton = foundObject.
pt();
145 else if(
useMet && fabs(foundObject.
id()) == 0){
146 met = foundObject.
pt();
148 else if(
usePFMet && fabs(foundObject.
id()) == 0){
151 else if(
useHT && fabs(foundObject.
id()) == 89){
152 ht = foundObject.
pt();
166 if(!MuonCollection->empty()){
167 float maxMuPt = -1.0;
168 for(
auto &
mu : *MuonCollection){
169 if(
mu.pt() > maxMuPt) maxMuPt =
mu.pt();
175 if(!PhotonCollection->empty()){
176 float maxPhoPt = -1.0;
177 for(
auto &pho : *PhotonCollection){
178 if(pho.pt() > maxPhoPt) maxPhoPt = pho.pt();
185 for (
auto const & i_calojet : *caloJetCollection){
186 if (i_calojet.pt() < 40)
continue;
187 if (fabs(i_calojet.eta()) > 3.0)
continue;
188 caloHT += i_calojet.pt();
edm::EDGetTokenT< reco::PhotonCollection > thePhotonCollection_
bool wasrun() const
Was at least one path run?
MonitorElement * h_PhotonPt
edm::EDGetTokenT< reco::MuonCollection > theMuonCollection_
trigger::size_type sizeFilters() const
edm::EDGetTokenT< reco::CaloJetCollection > theCaloJetCollection_
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
Strings::size_type size() const
MonitorElement * h_OnlinePhotonPt
std::vector< Muon > MuonCollection
collection of Muon objects
Single trigger physics object (e.g., an isolated muon)
edm::EDGetTokenT< edm::TriggerResults > triggerResults_
MonitorElement * h_OnlineMuPt
MonitorElement * h_OnlineHT
const TriggerObjectCollection & getObjects() const
edm::EDGetTokenT< reco::PFMETCollection > thePfMETCollection_
MonitorElement * h_OnlineMetPt
edm::InputTag triggerFilter_
std::vector< TriggerObject > TriggerObjectCollection
collection of trigger physics objects (e.g., all isolated muons)
MonitorElement * h_OnlinePFMetPt
static const char *const trigNames[]
edm::EDGetTokenT< trigger::TriggerEvent > theTrigSummary_
std::string const & triggerName(unsigned int index) const
std::vector< size_type > Keys
std::vector< Photon > PhotonCollection
collectin of Photon objects
edm::EDGetTokenT< reco::CaloMETCollection > theMETCollection_
MonitorElement * h_PFMetPt