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::EDConsumerBase 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 &)
 
std::function< void(BranchDescription
const &)> 
registrationCallback () const
 used by the fwk to register list of products More...
 
virtual ~ProducerBase ()
 
- Public Member Functions inherited from edm::EDConsumerBase
 EDConsumerBase ()
 
ProductHolderIndex indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductHolderIndex > &) const
 
void itemsToGet (BranchType, std::vector< ProductHolderIndex > &) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void updateLookup (BranchType iBranchType, ProductHolderIndexHelper const &)
 
virtual ~EDConsumerBase ()
 

Private Member Functions

void produce (edm::Event &e, const edm::EventSetup &) override
 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
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 

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  
)
overrideprivatevirtual

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(), customizeTrackingMonitorSeedNumber::idx, 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 energy() const GCC11_FINAL
energy
virtual float phi() const GCC11_FINAL
momentum azimuthal angle
double mCone
use only towers in cone mCone around L1 candidate for regional jet reco
edm::InputTag mTauTrigger
label of tau trigger type analysis
virtual float eta() const GCC11_FINAL
momentum pseudorapidity
PtEtaPhiELorentzVectorD PtEtaPhiELorentzVector
Lorentz vector with cartesian internal representation.
Definition: LorentzVector.h:28
tuple idx
DEBUGGING if hasattr(process,&quot;trackMonIterativeTracking2012&quot;): print &quot;trackMonIterativeTracking2012 D...
edm::InputTag mtowers
label of source collection
tuple cout
Definition: gather_cfg.py:121
double et(double vtxZ) const
Definition: CaloTower.h:101

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