CMS 3D CMS Logo

Classes | Public Member Functions | Private Types | Private Attributes

TriggerSummaryProducerAOD Class Reference

#include <TriggerSummaryProducerAOD.h>

Inheritance diagram for TriggerSummaryProducerAOD:
edm::EDProducer edm::ProducerBase edm::ProductRegistryHelper

List of all members.

Classes

struct  OrderInputTag
 InputTag ordering class. More...

Public Member Functions

virtual void endJob ()
void fillFilterObjectMember (const int &, const int &, const edm::Ref< reco::METCollection > &)
void fillFilterObjectMember (const int &, const int &, const edm::Ref< reco::CaloMETCollection > &)
template<typename C >
void fillFilterObjectMember (const int &, const int &, const edm::Ref< C > &)
void fillFilterObjectMember (const int &, const int &, const edm::Ref< l1extra::L1HFRingsCollection > &)
void fillFilterObjectMember (const int &, const int &, const edm::Ref< l1extra::L1EtMissParticleCollection > &)
template<typename C >
void fillFilterObjectMembers (const edm::Event &, const edm::InputTag &tag, const trigger::Vids &, const std::vector< edm::Ref< C > > &)
void fillTriggerObject (const reco::MET &)
void fillTriggerObject (const reco::CaloMET &)
void fillTriggerObject (const l1extra::L1EtMissParticle &)
template<typename T >
void fillTriggerObject (const T &)
void fillTriggerObject (const l1extra::L1HFRings &)
template<typename C >
void fillTriggerObjectCollections (const edm::Event &)
virtual void produce (edm::Event &, const edm::EventSetup &)
 TriggerSummaryProducerAOD (const edm::ParameterSet &)
 ~TriggerSummaryProducerAOD ()

Private Types

typedef std::set
< edm::InputTag, OrderInputTag
InputTagSet

Private Attributes

InputTagSet collectionTagsEvent_
 list of L3 collection tags
InputTagSet collectionTagsGlobal_
InputTagSet filterTagsEvent_
 list of L3 filter tags
InputTagSet filterTagsGlobal_
std::vector< edm::Handle
< trigger::TriggerFilterObjectWithRefs > > 
fobs_
 handles to the filter objects
trigger::Vids ids_
 ids
trigger::Keys keys_
 keys
std::vector< bool > maskFilters_
 packing decision
std::map< edm::ProductID,
unsigned int > 
offset_
 global map for indices into toc_: offset per input L3 collection
std::string pn_
 process name
edm::ProcessNameSelector selector_
 selector for getMany methods
std::vector< std::string > tags_
edm::service::TriggerNamesServicetns_
 the pointer to the current TriggerNamesService
trigger::TriggerObjectCollection toc_
 trigger object collection

Detailed Description

This class is an EDProducer making the HLT summary object for AOD

Date:
2010/11/09 13:58:42
Revision:
1.16
Author:
Martin Grunewald

See header file for documentation

Date:
2012/01/30 09:40:35
Revision:
1.45
Author:
Martin Grunewald

Definition at line 43 of file TriggerSummaryProducerAOD.h.


Member Typedef Documentation

Definition at line 101 of file TriggerSummaryProducerAOD.h.


Constructor & Destructor Documentation

TriggerSummaryProducerAOD::TriggerSummaryProducerAOD ( const edm::ParameterSet ps) [explicit]

Definition at line 60 of file TriggerSummaryProducerAOD.cc.

References collectionTagsEvent_, collectionTagsGlobal_, filterTagsEvent_, filterTagsGlobal_, edm::service::TriggerNamesService::getProcessName(), LogDebug, cppFunctionSkipper::operator, pn_, selector_, and tns_.

                                                                              : 
  pn_(ps.getParameter<std::string>("processName")),
  selector_(edm::ProcessNameSelector(pn_)),
  tns_(),
  filterTagsEvent_(pn_!="*"),
  filterTagsGlobal_(pn_!="*"),
  collectionTagsEvent_(pn_!="*"),
  collectionTagsGlobal_(pn_!="*"),
  toc_(),
  tags_(),
  offset_(),
  fobs_(),
  keys_(),
  ids_(),
  maskFilters_()
{
  if (pn_=="@") {
    // use tns
    if (edm::Service<edm::service::TriggerNamesService>().isAvailable()) {
      // get tns pointer
      tns_ = edm::Service<edm::service::TriggerNamesService>().operator->();
      if (tns_!=0) {
        pn_=tns_->getProcessName();
      } else {
        edm::LogError("TriggerSummaryProducerAOD") << "HLT Error: TriggerNamesService pointer = 0!";
        pn_="*";
      }
    } else {
      edm::LogError("TriggerSummaryProducerAOD") << "HLT Error: TriggerNamesService not available!";
      pn_="*";
    }
    selector_=edm::ProcessNameSelector(pn_);
    filterTagsEvent_     =InputTagSet(pn_!="*");
    filterTagsGlobal_    =InputTagSet(pn_!="*");
    collectionTagsEvent_ =InputTagSet(pn_!="*");
    collectionTagsGlobal_=InputTagSet(pn_!="*");
  }
  LogDebug("TriggerSummaryProducerAOD") << "Using process name: '" << pn_ <<"'";

  filterTagsGlobal_.clear();
  collectionTagsGlobal_.clear();

  produces<trigger::TriggerEvent>();

}
TriggerSummaryProducerAOD::~TriggerSummaryProducerAOD ( )

Definition at line 106 of file TriggerSummaryProducerAOD.cc.

{
}

Member Function Documentation

void TriggerSummaryProducerAOD::endJob ( void  ) [virtual]

Reimplemented from edm::EDProducer.

Definition at line 521 of file TriggerSummaryProducerAOD.cc.

References collectionTagsGlobal_, benchmark_cfg::fb, and filterTagsGlobal_.

                                       {

  using namespace std;
  using namespace edm;
  using namespace trigger;

  LogVerbatim("TriggerSummaryProducerAOD") << endl;
  LogVerbatim("TriggerSummaryProducerAOD") << "TriggerSummaryProducerAOD::endJob - accumulated tags:" << endl;

  const unsigned int nc(collectionTagsGlobal_.size());
  const unsigned int nf(filterTagsGlobal_.size());
  LogVerbatim("TriggerSummaryProducerAOD") << " Overall number of Collections/Filters: "
                  << nc << "/" << nf << endl;

  LogVerbatim("TriggerSummaryProducerAOD") << " The collections: " << nc << endl;
  const InputTagSet::const_iterator cb(collectionTagsGlobal_.begin());
  const InputTagSet::const_iterator ce(collectionTagsGlobal_.end());
  for ( InputTagSet::const_iterator ci=cb; ci!=ce; ++ci) {
    LogVerbatim("TriggerSummaryProducerAOD") << "  " << distance(cb,ci) << " " << ci->encode() << endl;
  }

  LogVerbatim("TriggerSummaryProducerAOD") << " The filters:" << nf << endl;
  const InputTagSet::const_iterator fb(filterTagsGlobal_.begin());
  const InputTagSet::const_iterator fe(filterTagsGlobal_.end());
  for ( InputTagSet::const_iterator fi=fb; fi!=fe; ++fi) {
    LogVerbatim("TriggerSummaryProducerAOD") << "  " << distance(fb,fi) << " " << fi->encode() << endl;
  }

  LogVerbatim("TriggerSummaryProducerAOD") << "TriggerSummaryProducerAOD::endJob." << endl;
  LogVerbatim("TriggerSummaryProducerAOD") << endl;

  return;

}
template<typename C >
void TriggerSummaryProducerAOD::fillFilterObjectMember ( const int &  offset,
const int &  id,
const edm::Ref< C > &  ref 
)

Definition at line 449 of file TriggerSummaryProducerAOD.cc.

References ids_, edm::Ref< C, T, F >::key(), and keys_.

Referenced by fillFilterObjectMembers().

                                                                                                              {

  keys_.push_back(offset+ref.key());
  ids_.push_back(id);

  return;
}
void TriggerSummaryProducerAOD::fillFilterObjectMember ( const int &  offset,
const int &  id,
const edm::Ref< l1extra::L1HFRingsCollection > &  ref 
)

Definition at line 457 of file TriggerSummaryProducerAOD.cc.

References ids_, edm::Ref< C, T, F >::key(), keys_, and trigger::TriggerL1HfBitCounts.

                                                                                                                                       {

  using namespace trigger;

  if (id==TriggerL1HfBitCounts) {
    keys_.push_back(offset+2*ref.key()+1);
  } else { // if (ids[i]==TriggerL1HfRingEtSums) {
    keys_.push_back(offset+2*ref.key()+0);
  }
  ids_.push_back(id);

  return;
}
void TriggerSummaryProducerAOD::fillFilterObjectMember ( const int &  offset,
const int &  id,
const edm::Ref< l1extra::L1EtMissParticleCollection > &  ref 
)

Definition at line 471 of file TriggerSummaryProducerAOD.cc.

References ids_, edm::Ref< C, T, F >::key(), keys_, trigger::TriggerL1ETT, and trigger::TriggerL1HTT.

                                                                                                                                              {

  using namespace trigger;

  if ( (id==TriggerL1ETT) || (id==TriggerL1HTT) ) {
    keys_.push_back(offset+2*ref.key()+1);
  } else {
    keys_.push_back(offset+2*ref.key()+0);
  }
  ids_.push_back(id);

  return;
}
void TriggerSummaryProducerAOD::fillFilterObjectMember ( const int &  offset,
const int &  id,
const edm::Ref< reco::CaloMETCollection > &  ref 
)

Definition at line 485 of file TriggerSummaryProducerAOD.cc.

References ids_, edm::Ref< C, T, F >::key(), keys_, trigger::TriggerELongit, trigger::TriggerHLongit, trigger::TriggerMETSig, trigger::TriggerMHTSig, trigger::TriggerTET, and trigger::TriggerTHT.

                                                                                                                                  {

  using namespace trigger;

  if ( (id==TriggerTHT) || (id==TriggerTET) ) {
    keys_.push_back(offset+4*ref.key()+1);
  } else if ( (id==TriggerMETSig) || (id==TriggerMHTSig) ) {
    keys_.push_back(offset+4*ref.key()+2);
  } else if ( (id==TriggerELongit) || (id==TriggerHLongit) ) {
    keys_.push_back(offset+4*ref.key()+3);
  } else {
    keys_.push_back(offset+4*ref.key()+0);
  }
  ids_.push_back(id);

  return;
}
void TriggerSummaryProducerAOD::fillFilterObjectMember ( const int &  offset,
const int &  id,
const edm::Ref< reco::METCollection > &  ref 
)

Definition at line 503 of file TriggerSummaryProducerAOD.cc.

References ids_, edm::Ref< C, T, F >::key(), keys_, trigger::TriggerELongit, trigger::TriggerHLongit, trigger::TriggerMETSig, trigger::TriggerMHTSig, trigger::TriggerTET, and trigger::TriggerTHT.

                                                                                                                              {

  using namespace trigger;

  if ( (id==TriggerTHT) || (id==TriggerTET) ) {
    keys_.push_back(offset+4*ref.key()+1);
  } else if ( (id==TriggerMETSig) || (id==TriggerMHTSig) ) {
    keys_.push_back(offset+4*ref.key()+2);
  } else if ( (id==TriggerELongit) || (id==TriggerHLongit) ) {
    keys_.push_back(offset+4*ref.key()+3);
  } else {
    keys_.push_back(offset+4*ref.key()+0);
  }
  ids_.push_back(id);

  return;
}
template<typename C >
void TriggerSummaryProducerAOD::fillFilterObjectMembers ( const edm::Event iEvent,
const edm::InputTag tag,
const trigger::Vids ids,
const std::vector< edm::Ref< C > > &  refs 
)

this routine takes a vector of Ref<C>s and determines the corresponding vector of keys (i.e., indices) into the TriggerObjectCollection

Definition at line 408 of file TriggerSummaryProducerAOD.cc.

References funct::C, edm::InputTag::encode(), fillFilterObjectMember(), edm::Event::getProvenance(), i, instance, label, min, edm::Provenance::moduleLabel(), n, mergeVDriftHistosByStation::name, offset_, evf::utils::pid, LaserDQM_cfg::process, edm::Provenance::processName(), edm::Provenance::productInstanceName(), and dt_dqm_sourceclient_common_cff::reco.

Referenced by produce().

                                                                                                                                                                 {


  using namespace std;
  using namespace edm;
  using namespace reco;
  using namespace l1extra;
  using namespace trigger;

  if (ids.size()!=refs.size()) {
    LogError("TriggerSummaryProducerAOD") << "Vector length is different: "
                                          << ids.size() << " " << refs.size();
  }

  const unsigned int n(min(ids.size(),refs.size()));
  for (unsigned int i=0; i!=n; ++i) {
    const ProductID pid(refs[i].id());
    if (offset_.find(pid)==offset_.end()) {
      const string&    label(iEvent.getProvenance(pid).moduleLabel());
      const string& instance(iEvent.getProvenance(pid).productInstanceName());
      const string&  process(iEvent.getProvenance(pid).processName());
      LogError("TriggerSummaryProducerAOD")
        << "Uunknown pid:"
        << " FilterTag/Key: " << tag.encode()
        << "/" << i
        << " CollectionTag/Key: "
        << InputTag(label,instance,process).encode()
        << "/" << refs[i].key()
        << " CollectionType: " << typeid(C).name();
    } else {
      fillFilterObjectMember(offset_[pid],ids[i],refs[i]);
    }
  }
  return;

}
void TriggerSummaryProducerAOD::fillTriggerObject ( const reco::MET object)

Definition at line 394 of file TriggerSummaryProducerAOD.cc.

References dt_dqm_sourceclient_common_cff::reco, toc_, trigger::TriggerHLongit, trigger::TriggerMHTSig, and trigger::TriggerTHT.

                                                                       {

  using namespace reco;
  using namespace trigger;

  toc_.push_back( TriggerObject(object) );
  toc_.push_back(TriggerObject(TriggerTHT    ,object.sumEt()         ,0.0,0.0,0.0));
  toc_.push_back(TriggerObject(TriggerMHTSig ,object.mEtSig()        ,0.0,0.0,0.0));
  toc_.push_back(TriggerObject(TriggerHLongit,object.e_longitudinal(),0.0,0.0,0.0));

  return;
}
void TriggerSummaryProducerAOD::fillTriggerObject ( const reco::CaloMET object)

Definition at line 381 of file TriggerSummaryProducerAOD.cc.

References dt_dqm_sourceclient_common_cff::reco, toc_, trigger::TriggerELongit, trigger::TriggerMETSig, and trigger::TriggerTET.

                                                                           {

  using namespace reco;
  using namespace trigger;

  toc_.push_back( TriggerObject(object) );
  toc_.push_back(TriggerObject(TriggerTET    ,object.sumEt()         ,0.0,0.0,0.0));
  toc_.push_back(TriggerObject(TriggerMETSig ,object.mEtSig()        ,0.0,0.0,0.0));
  toc_.push_back(TriggerObject(TriggerELongit,object.e_longitudinal(),0.0,0.0,0.0));

  return;
}
template<typename T >
void TriggerSummaryProducerAOD::fillTriggerObject ( const T object)

Definition at line 337 of file TriggerSummaryProducerAOD.cc.

References toc_.

Referenced by fillTriggerObjectCollections().

                                                                 {

  using namespace trigger;
  toc_.push_back( TriggerObject(object) );

  return;
}
void TriggerSummaryProducerAOD::fillTriggerObject ( const l1extra::L1EtMissParticle object)

Definition at line 364 of file TriggerSummaryProducerAOD.cc.

References toc_, trigger::TriggerL1ETT, and trigger::TriggerL1HTT.

                                                                                       {

  using namespace l1extra;
  using namespace trigger;

  toc_.push_back( TriggerObject(object) );
  if (object.type()==L1EtMissParticle::kMET) {
    toc_.push_back(TriggerObject(TriggerL1ETT,object.etTotal(),0.0,0.0,0.0));
  } else if (object.type()==L1EtMissParticle::kMHT) {
    toc_.push_back(TriggerObject(TriggerL1HTT,object.etTotal(),0.0,0.0,0.0));
  } else {
    toc_.push_back(TriggerObject(0,           object.etTotal(),0.0,0.0,0.0));
  }

  return;
}
void TriggerSummaryProducerAOD::fillTriggerObject ( const l1extra::L1HFRings object)

Definition at line 345 of file TriggerSummaryProducerAOD.cc.

References toc_, trigger::TriggerL1HfBitCounts, and trigger::TriggerL1HfRingEtSums.

                                                                                {

  using namespace l1extra;
  using namespace trigger;

  toc_.push_back(TriggerObject(TriggerL1HfRingEtSums,
       object.hfEtSum(L1HFRings::kRing1PosEta),
       object.hfEtSum(L1HFRings::kRing1NegEta),
       object.hfEtSum(L1HFRings::kRing2PosEta),
       object.hfEtSum(L1HFRings::kRing2NegEta) ) );
  toc_.push_back(TriggerObject(TriggerL1HfBitCounts,
       object.hfBitCount(L1HFRings::kRing1PosEta),
       object.hfBitCount(L1HFRings::kRing1NegEta),
       object.hfBitCount(L1HFRings::kRing2PosEta),
       object.hfBitCount(L1HFRings::kRing2NegEta) ) );

  return;
}
template<typename C >
void TriggerSummaryProducerAOD::fillTriggerObjectCollections ( const edm::Event iEvent)

this routine accesses the original (L3) collections (with C++ typename C), extracts 4-momentum and id of each collection member, and packs this up

end loop over handles

Definition at line 296 of file TriggerSummaryProducerAOD.cc.

References collectionTagsEvent_, fillTriggerObject(), edm::Event::getMany(), i, instance, keys_, label, edm::Provenance::moduleLabel(), n, offset_, evf::utils::pid, LaserDQM_cfg::process, edm::Provenance::processName(), edm::Provenance::productInstanceName(), dt_dqm_sourceclient_common_cff::reco, selector_, findQualityFiles::size, tags_, and toc_.

                                                                                   {


  using namespace std;
  using namespace edm;
  using namespace reco;
  using namespace l1extra;
  using namespace trigger;

  vector<Handle<C> > collections;
  iEvent.getMany(selector_,collections);
  const unsigned int nc(collections.size());

  for (unsigned int ic=0; ic!=nc; ++ic) {
    const Provenance& provenance(*(collections[ic].provenance()));
    const string& label    (provenance.moduleLabel());
    const string& instance (provenance.productInstanceName());
    const string& process  (provenance.processName());
    const InputTag collectionTag(label,instance,process);

    if (collectionTagsEvent_.find(collectionTag)!=collectionTagsEvent_.end()) {
      const ProductID pid(collections[ic].provenance()->productID());
      if (offset_.find(pid)!=offset_.end()) {
        LogError("TriggerSummaryProducerAOD") << "Duplicate pid!";
      }
      offset_[pid]=toc_.size();
      const unsigned int n(collections[ic]->size());
      for (unsigned int i=0; i!=n; ++i) {
        fillTriggerObject( (*collections[ic])[i] );
      }
      tags_.push_back(collectionTag.encode());
      keys_.push_back(toc_.size());
    }

  } 
}
void TriggerSummaryProducerAOD::produce ( edm::Event iEvent,
const edm::EventSetup iSetup 
) [virtual]

get hold of filter objects

check whether collection tags are recorded in filterobjects; if so, these are L3 collections to be packed up, and the corresponding filter is a L3 filter also to be packed up. Record the InputTags of those L3 filters and L3 collections.

check uniqueness count

accumulate for endJob printout

debug printout

event-by-event tags

Now the processing: first trigger objects from L3 collections, then L3 filter objects

create trigger objects, fill triggerobjectcollection and offset map

construct single AOD product, reserving capacity

fill trigger object collection

fill the L3 filter objects

Implements edm::EDProducer.

Definition at line 144 of file TriggerSummaryProducerAOD.cc.

References collectionTagsEvent_, collectionTagsGlobal_, benchmark_cfg::fb, fillFilterObjectMembers(), filterTagsEvent_, filterTagsGlobal_, fobs_, edm::Event::getMany(), ids_, iEvent, instance, edm::isDebugEnabled(), keys_, label, LogDebug, LogTrace, maskFilters_, offset_, pn_, LaserDQM_cfg::process, edm::Event::put(), dt_dqm_sourceclient_common_cff::reco, selector_, tags_, and toc_.

{
   using namespace std;
   using namespace edm;
   using namespace reco;
   using namespace l1extra;
   using namespace trigger;

   fobs_.clear();
   iEvent.getMany(selector_,fobs_);
   const unsigned int nfob(fobs_.size());
   LogTrace("TriggerSummaryProducerAOD") << "Number of filter  objects found: " << nfob;

   string tagLabel,tagInstance,tagProcess;

   maskFilters_.clear();
   maskFilters_.resize(nfob);
   filterTagsEvent_.clear();
   collectionTagsEvent_.clear();
   unsigned int nf(0);
   for (unsigned int ifob=0; ifob!=nfob; ++ifob) {
     maskFilters_[ifob]=false;
     const vector<string>& collectionTags_(fobs_[ifob]->getCollectionTagsAsStrings());
     const unsigned int ncol(collectionTags_.size());
     if (ncol>0) {
       nf++;
       maskFilters_[ifob]=true;
       const string& label    (fobs_[ifob].provenance()->moduleLabel());
       const string& instance (fobs_[ifob].provenance()->productInstanceName());
       const string& process  (fobs_[ifob].provenance()->processName());
       filterTagsEvent_.insert(InputTag(label,instance,process));
       for (unsigned int icol=0; icol!=ncol; ++icol) {
         // overwrite process name (usually not set)
         tokenizeTag(collectionTags_[icol],tagLabel,tagInstance,tagProcess);
         collectionTagsEvent_.insert(InputTag(tagLabel,tagInstance,pn_));
       }
     }
   }
   if (filterTagsEvent_.size()!=nf) {
     LogError("TriggerSummaryProducerAOD")
       << "Mismatch in number of filter tags: "
       << filterTagsEvent_.size() << "!=" << nf ;
   }

   collectionTagsGlobal_.insert(collectionTagsEvent_.begin(),collectionTagsEvent_.end());
   filterTagsGlobal_.insert(filterTagsEvent_.begin(),filterTagsEvent_.end());

   if (isDebugEnabled()) {

     const unsigned int nc(collectionTagsEvent_.size());
     LogTrace("TriggerSummaryProducerAOD") << "Number of unique collections requested " << nc;
     const InputTagSet::const_iterator cb(collectionTagsEvent_.begin());
     const InputTagSet::const_iterator ce(collectionTagsEvent_.end());
     for ( InputTagSet::const_iterator ci=cb; ci!=ce; ++ci) {
       LogTrace("TriggerSummaryProducerAOD") << distance(cb,ci) << " " << ci->encode();
     }
     const unsigned int nf(filterTagsEvent_.size());
     LogTrace("TriggerSummaryProducerAOD") << "Number of unique filters requested " << nf;
     const InputTagSet::const_iterator fb(filterTagsEvent_.begin());
     const InputTagSet::const_iterator fe(filterTagsEvent_.end());
     for ( InputTagSet::const_iterator fi=fb; fi!=fe; ++fi) {
       LogTrace("TriggerSummaryProducerAOD") << distance(fb,fi) << " " << fi->encode();
     }

   }

   toc_.clear();
   tags_.clear();
   keys_.clear();
   offset_.clear();
   fillTriggerObjectCollections<          RecoEcalCandidateCollection>(iEvent);
   fillTriggerObjectCollections<                   ElectronCollection>(iEvent);
   fillTriggerObjectCollections<       RecoChargedCandidateCollection>(iEvent);
   fillTriggerObjectCollections<                    CaloJetCollection>(iEvent);
   fillTriggerObjectCollections<         CompositeCandidateCollection>(iEvent);
   fillTriggerObjectCollections<                        METCollection>(iEvent);
   fillTriggerObjectCollections<                    CaloMETCollection>(iEvent);
   fillTriggerObjectCollections<IsolatedPixelTrackCandidateCollection>(iEvent);
   fillTriggerObjectCollections<               L1EmParticleCollection>(iEvent);
   fillTriggerObjectCollections<             L1MuonParticleCollection>(iEvent);
   fillTriggerObjectCollections<              L1JetParticleCollection>(iEvent);
   fillTriggerObjectCollections<           L1EtMissParticleCollection>(iEvent);
   fillTriggerObjectCollections<                  L1HFRingsCollection>(iEvent);
   fillTriggerObjectCollections<                      PFJetCollection>(iEvent);
   fillTriggerObjectCollections<                      PFTauCollection>(iEvent);
   const unsigned int nk(tags_.size());
   LogDebug("TriggerSummaryProducerAOD") << "Number of collections found: " << nk;
   const unsigned int no(toc_.size());
   LogDebug("TriggerSummaryProducerAOD") << "Number of physics objects found: " << no;

   auto_ptr<TriggerEvent> product(new TriggerEvent(pn_,nk,no,nf));

   product->addCollections(tags_,keys_);
   product->addObjects(toc_);

   for (unsigned int ifob=0; ifob!=nfob; ++ifob) {
     if (maskFilters_[ifob]) {
       const string& label    (fobs_[ifob].provenance()->moduleLabel());
       const string& instance (fobs_[ifob].provenance()->productInstanceName());
       const string& process  (fobs_[ifob].provenance()->processName());
       const edm::InputTag filterTag(label,instance,process);
       ids_.clear();
       keys_.clear();
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->photonIds()   ,fobs_[ifob]->photonRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->electronIds() ,fobs_[ifob]->electronRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->muonIds()     ,fobs_[ifob]->muonRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->jetIds()      ,fobs_[ifob]->jetRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->compositeIds(),fobs_[ifob]->compositeRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->basemetIds()  ,fobs_[ifob]->basemetRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->calometIds()  ,fobs_[ifob]->calometRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->pixtrackIds() ,fobs_[ifob]->pixtrackRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->l1emIds()     ,fobs_[ifob]->l1emRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->l1muonIds()   ,fobs_[ifob]->l1muonRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->l1jetIds()    ,fobs_[ifob]->l1jetRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->l1etmissIds() ,fobs_[ifob]->l1etmissRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->l1hfringsIds(),fobs_[ifob]->l1hfringsRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->pfjetIds()    ,fobs_[ifob]->pfjetRefs());
       fillFilterObjectMembers(iEvent,filterTag,fobs_[ifob]->pftauIds()    ,fobs_[ifob]->pftauRefs());
       product->addFilter(filterTag,ids_,keys_);
     }
   }

   OrphanHandle<TriggerEvent> ref = iEvent.put(product);
   LogTrace("TriggerSummaryProducerAOD") << "Number of physics objects packed: " << ref->sizeObjects();
   LogTrace("TriggerSummaryProducerAOD") << "Number of filter  objects packed: " << ref->sizeFilters();

}

Member Data Documentation

list of L3 collection tags

Definition at line 108 of file TriggerSummaryProducerAOD.h.

Referenced by fillTriggerObjectCollections(), produce(), and TriggerSummaryProducerAOD().

Definition at line 109 of file TriggerSummaryProducerAOD.h.

Referenced by endJob(), produce(), and TriggerSummaryProducerAOD().

list of L3 filter tags

Definition at line 104 of file TriggerSummaryProducerAOD.h.

Referenced by produce(), and TriggerSummaryProducerAOD().

Definition at line 105 of file TriggerSummaryProducerAOD.h.

Referenced by endJob(), produce(), and TriggerSummaryProducerAOD().

handles to the filter objects

Definition at line 118 of file TriggerSummaryProducerAOD.h.

Referenced by produce().

ids

Definition at line 122 of file TriggerSummaryProducerAOD.h.

Referenced by fillFilterObjectMember(), and produce().

std::vector<bool> TriggerSummaryProducerAOD::maskFilters_ [private]

packing decision

Definition at line 125 of file TriggerSummaryProducerAOD.h.

Referenced by produce().

std::map<edm::ProductID,unsigned int> TriggerSummaryProducerAOD::offset_ [private]

global map for indices into toc_: offset per input L3 collection

Definition at line 115 of file TriggerSummaryProducerAOD.h.

Referenced by fillFilterObjectMembers(), fillTriggerObjectCollections(), and produce().

std::string TriggerSummaryProducerAOD::pn_ [private]

process name

Definition at line 75 of file TriggerSummaryProducerAOD.h.

Referenced by produce(), and TriggerSummaryProducerAOD().

selector for getMany methods

Definition at line 78 of file TriggerSummaryProducerAOD.h.

Referenced by fillTriggerObjectCollections(), produce(), and TriggerSummaryProducerAOD().

std::vector<std::string> TriggerSummaryProducerAOD::tags_ [private]

Definition at line 113 of file TriggerSummaryProducerAOD.h.

Referenced by fillTriggerObjectCollections(), and produce().

the pointer to the current TriggerNamesService

Definition at line 81 of file TriggerSummaryProducerAOD.h.

Referenced by TriggerSummaryProducerAOD().

trigger object collection

Definition at line 112 of file TriggerSummaryProducerAOD.h.

Referenced by fillTriggerObject(), fillTriggerObjectCollections(), and produce().