CMS 3D CMS Logo

CaloTowerCreatorForTauHLT Class Reference

Framework module that produces a collection of calo towers in the region of interest for Tau HLT reconnstruction, depending on tau type trigger: Tau1 - take location of 1st L1 Tau Tau2 - take location of 2nd L1 Tau; if does not exists, take location of 1st Calo Tower ETau - take L1 Tau candidate which is not collinear to HLT (or L1) electron candidate. More...

#include <RecoTauTag/HLTProducers/interface/CaloTowerCreatorForTauHLT.h>

Inheritance diagram for CaloTowerCreatorForTauHLT:

edm::EDProducer edm::ProducerBase edm::ProductRegistryHelper

List of all members.

Public Member Functions

 CaloTowerCreatorForTauHLT (const edm::ParameterSet &)
 constructor from parameter set
 ~CaloTowerCreatorForTauHLT ()
 destructor

Private Member Functions

void produce (edm::Event &e, const edm::EventSetup &)
 process one event

Private Attributes

double mCone
 use only towers in cone mCone around L1 candidate for regional jet reco
double mEThreshold
 E threshold.
double mEtThreshold
 ET threshold.
edm::InputTag ml1seeds
 imitator of L1 seeds
int mTauId
edm::InputTag mTauTrigger
 label of tau trigger type analysis
edm::InputTag mtowers
 label of source collection
int mVerbose
 verbosity


Detailed Description

Framework module that produces a collection of calo towers in the region of interest for Tau HLT reconnstruction, depending on tau type trigger: Tau1 - take location of 1st L1 Tau Tau2 - take location of 2nd L1 Tau; if does not exists, take location of 1st Calo Tower ETau - take L1 Tau candidate which is not collinear to HLT (or L1) electron candidate.

Author:
A. Nikitenko. IC. based on L. Lista and J. Mans

Definition at line 27 of file CaloTowerCreatorForTauHLT.h.


Constructor & Destructor Documentation

CaloTowerCreatorForTauHLT::CaloTowerCreatorForTauHLT ( const edm::ParameterSet p  ) 

constructor from parameter set

Definition at line 23 of file CaloTowerCreatorForTauHLT.cc.

00024   :
00025   mVerbose (p.getUntrackedParameter<int> ("verbose", 0)),
00026   mtowers (p.getParameter<InputTag> ("towers")),
00027   mCone (p.getParameter<double> ("UseTowersInCone")),
00028   mTauTrigger (p.getParameter<InputTag> ("TauTrigger")),
00029 //  ml1seeds (p.getParameter<InputTag> ("l1seeds")),
00030   mEtThreshold (p.getParameter<double> ("minimumEt")),
00031   mEThreshold (p.getParameter<double> ("minimumE")),
00032   mTauId (p.getParameter<int> ("TauId"))
00033 {
00034   produces<CaloTowerCollection>();
00035 }

CaloTowerCreatorForTauHLT::~CaloTowerCreatorForTauHLT (  ) 

destructor

Definition at line 37 of file CaloTowerCreatorForTauHLT.cc.

00037                                                       {
00038 }


Member Function Documentation

void CaloTowerCreatorForTauHLT::produce ( edm::Event e,
const edm::EventSetup  
) [private, virtual]

process one event

Implements edm::EDProducer.

Definition at line 40 of file CaloTowerCreatorForTauHLT.cc.

References IterativeConePu5Jets_PbPb_cff::caloTowers, GenMuonPlsPt100GeV_cfg::cout, lat::endl(), reco::Particle::energy(), reco::Particle::et(), reco::Particle::eta(), edm::Event::getByLabel(), mCone, mEThreshold, mEtThreshold, mTauId, mTauTrigger, mtowers, mVerbose, p, reco::Particle::phi(), and edm::Event::put().

00040                                                                        {
00041   Handle<CaloTowerCollection> caloTowers;
00042   evt.getByLabel( mtowers, caloTowers );
00043 
00044   // imitate L1 seeds
00045   Handle<L1JetParticleCollection> jetsgen;
00046   evt.getByLabel(mTauTrigger, jetsgen);
00047   auto_ptr<CaloTowerCollection> cands( new CaloTowerCollection );
00048   cands->reserve( caloTowers->size() );
00049   
00050   int idTau =0;
00051   L1JetParticleCollection::const_iterator myL1Jet = jetsgen->begin();
00052   for(;myL1Jet != jetsgen->end();myL1Jet++)
00053     {
00054       if(idTau == mTauId)
00055         {
00056           double Sum08 = 0.;
00057           
00058           unsigned idx = 0;
00059           for (; idx < caloTowers->size(); idx++) {
00060             const CaloTower* cal = &((*caloTowers) [idx]);
00061             if (mVerbose == 2) {
00062               std::cout << "CaloTowerCreatorForTauHLT::produce-> " << idx << " tower et/eta/phi/e: " 
00063                         << cal->et() << '/' << cal->eta() << '/' << cal->phi() << '/' << cal->energy() << " is...";
00064             }
00065             if (cal->et() >= mEtThreshold && cal->energy() >= mEThreshold ) {
00066               math::PtEtaPhiELorentzVector p( cal->et(), cal->eta(), cal->phi(), cal->energy() );
00067               double delta  = ROOT::Math::VectorUtil::DeltaR((*myL1Jet).p4().Vect(), p);
00068               
00069               if(delta < mCone) {
00070                 Sum08 += cal->et(); 
00071                 cands->push_back( *cal );
00072               }
00073             }
00074             else {
00075               if (mVerbose == 2) std::cout << "rejected " << std::endl;
00076             }
00077           }
00078 
00079         }
00080       idTau++;
00081     }
00082 
00083   evt.put( cands );
00084   
00085 }


Member Data Documentation

double CaloTowerCreatorForTauHLT::mCone [private]

use only towers in cone mCone around L1 candidate for regional jet reco

Definition at line 42 of file CaloTowerCreatorForTauHLT.h.

Referenced by produce().

double CaloTowerCreatorForTauHLT::mEThreshold [private]

E threshold.

Definition at line 50 of file CaloTowerCreatorForTauHLT.h.

Referenced by produce().

double CaloTowerCreatorForTauHLT::mEtThreshold [private]

ET threshold.

Definition at line 48 of file CaloTowerCreatorForTauHLT.h.

Referenced by produce().

edm::InputTag CaloTowerCreatorForTauHLT::ml1seeds [private]

imitator of L1 seeds

Definition at line 46 of file CaloTowerCreatorForTauHLT.h.

int CaloTowerCreatorForTauHLT::mTauId [private]

Definition at line 53 of file CaloTowerCreatorForTauHLT.h.

Referenced by produce().

edm::InputTag CaloTowerCreatorForTauHLT::mTauTrigger [private]

label of tau trigger type analysis

Definition at line 44 of file CaloTowerCreatorForTauHLT.h.

Referenced by produce().

edm::InputTag CaloTowerCreatorForTauHLT::mtowers [private]

label of source collection

Definition at line 40 of file CaloTowerCreatorForTauHLT.h.

Referenced by produce().

int CaloTowerCreatorForTauHLT::mVerbose [private]

verbosity

Definition at line 38 of file CaloTowerCreatorForTauHLT.h.

Referenced by produce().


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:15:59 2009 for CMSSW by  doxygen 1.5.4