CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Member Functions | Private Attributes
CaloTowerCreatorForTauHLT Class Reference

#include <CaloTowerCreatorForTauHLT.h>

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

Public Member Functions

 CaloTowerCreatorForTauHLT (const edm::ParameterSet &)
 constructor from parameter set More...
 
 ~CaloTowerCreatorForTauHLT ()
 destructor More...
 
- Public Member Functions inherited from edm::EDProducer
 EDProducer ()
 
virtual ~EDProducer ()
 
- Public Member Functions inherited from edm::ProducerBase
 ProducerBase ()
 
void registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &)
 
boost::function< void(const
BranchDescription &)> 
registrationCallback () const
 used by the fwk to register list of products More...
 
virtual ~ProducerBase ()
 

Private Member Functions

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

Private Attributes

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

Additional Inherited Members

- Public Types inherited from edm::EDProducer
typedef EDProducer ModuleType
 
typedef WorkerT< EDProducerWorkerType
 
- Public Types inherited from edm::ProducerBase
typedef
ProductRegistryHelper::TypeLabelList 
TypeLabelList
 
- Static Public Member Functions inherited from edm::EDProducer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 
- Protected Member Functions inherited from edm::EDProducer
CurrentProcessingContext const * currentContext () const
 
- Protected Member Functions inherited from edm::ProducerBase
template<class TProducer , class TMethod >
void callWhenNewProductsRegistered (TProducer *iProd, TMethod iMethod)
 

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.

24  :
25  mVerbose (p.getUntrackedParameter<int> ("verbose", 0)),
26  mtowers (p.getParameter<InputTag> ("towers")),
27  mCone (p.getParameter<double> ("UseTowersInCone")),
28  mTauTrigger (p.getParameter<InputTag> ("TauTrigger")),
29 // ml1seeds (p.getParameter<InputTag> ("l1seeds")),
30  mEtThreshold (p.getParameter<double> ("minimumEt")),
31  mEThreshold (p.getParameter<double> ("minimumE")),
32  mTauId (p.getParameter<int> ("TauId"))
33 {
34  produces<CaloTowerCollection>();
35 }
T getParameter(std::string const &) const
T getUntrackedParameter(std::string const &, T const &) const
double mCone
use only towers in cone mCone around L1 candidate for regional jet reco
edm::InputTag mTauTrigger
label of tau trigger type analysis
edm::InputTag mtowers
label of source collection
CaloTowerCreatorForTauHLT::~CaloTowerCreatorForTauHLT ( )

destructor

Definition at line 37 of file CaloTowerCreatorForTauHLT.cc.

37  {
38 }

Member Function Documentation

void CaloTowerCreatorForTauHLT::produce ( edm::Event e,
const edm::EventSetup  
)
privatevirtual

process one event

Implements edm::EDProducer.

Definition at line 40 of file CaloTowerCreatorForTauHLT.cc.

References HiRecoJets_cff::caloTowers, gather_cfg::cout, delta, reco::LeafCandidate::energy(), CaloTower::et(), reco::LeafCandidate::eta(), edm::Event::getByLabel(), mCone, mEThreshold, mEtThreshold, mTauId, mTauTrigger, mtowers, mVerbose, AlCaHLTBitMon_ParallelJobs::p, reco::LeafCandidate::phi(), and edm::Event::put().

40  {
42  evt.getByLabel( mtowers, caloTowers );
43 
44  // imitate L1 seeds
46  evt.getByLabel(mTauTrigger, jetsgen);
47  std::auto_ptr<CaloTowerCollection> cands( new CaloTowerCollection );
48  cands->reserve( caloTowers->size() );
49 
50  int idTau =0;
51  L1JetParticleCollection::const_iterator myL1Jet = jetsgen->begin();
52  for(;myL1Jet != jetsgen->end();myL1Jet++)
53  {
54  if(idTau == mTauId)
55  {
56  double Sum08 = 0.;
57 
58  unsigned idx = 0;
59  for (; idx < caloTowers->size(); idx++) {
60  const CaloTower* cal = &((*caloTowers) [idx]);
61  if (mVerbose == 2) {
62  std::cout << "CaloTowerCreatorForTauHLT::produce-> " << idx << " tower et/eta/phi/e: "
63  << cal->et() << '/' << cal->eta() << '/' << cal->phi() << '/' << cal->energy() << " is...";
64  }
65  if (cal->et() >= mEtThreshold && cal->energy() >= mEThreshold ) {
66  math::PtEtaPhiELorentzVector p( cal->et(), cal->eta(), cal->phi(), cal->energy() );
67  double delta = ROOT::Math::VectorUtil::DeltaR((*myL1Jet).p4().Vect(), p);
68 
69  if(delta < mCone) {
70  Sum08 += cal->et();
71  cands->push_back( *cal );
72  }
73  }
74  else {
75  if (mVerbose == 2) std::cout << "rejected " << std::endl;
76  }
77  }
78 
79  }
80  idTau++;
81  }
82 
83  evt.put( cands );
84 
85 }
dbl * delta
Definition: mlp_gen.cc:36
virtual double eta() const
momentum pseudorapidity
virtual double energy() const
energy
double mCone
use only towers in cone mCone around L1 candidate for regional jet reco
edm::InputTag mTauTrigger
label of tau trigger type analysis
PtEtaPhiELorentzVectorD PtEtaPhiELorentzVector
Lorentz vector with cartesian internal representation.
Definition: LorentzVector.h:28
edm::InputTag mtowers
label of source collection
tuple cout
Definition: gather_cfg.py:121
double et(double vtxZ) const
Definition: CaloTower.h:101
virtual double phi() const
momentum azimuthal angle

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().